📄 unit_sell.pas
字号:
unit Unit_Sell;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ExtCtrls, Grids, Buttons, Spin;
type
TFrame_Sell = class(TFrame)
Panel5: TPanel;
GroupBox1: TGroupBox;
RadioButton1: TRadioButton;
RadioButton2: TRadioButton;
RadioButton3: TRadioButton;
Notebook1: TNotebook;
Edt_ProQry: TEdit;
ComboBox2: TComboBox;
ComboBox1: TComboBox;
RadioGroup1: TRadioGroup;
SpinEdit1: TSpinEdit;
BitBtn_qry: TBitBtn;
Panel2: TPanel;
BitBtn_new: TBitBtn;
BitBtn_edit: TBitBtn;
BitBtn_del: TBitBtn;
BitBtn_ok: TBitBtn;
BitBtn_cancel: TBitBtn;
Panel1: TPanel;
Panel3: TPanel;
StringGrid1: TStringGrid;
Panel4: TPanel;
Label1: TLabel;
Label2: TLabel;
Label3: TLabel;
Label4: TLabel;
Image1: TImage;
Label5: TLabel;
Label6: TLabel;
Mmo_Des: TMemo;
Edt_Price: TSpinEdit;
ComboBox3: TComboBox;
ComboBox4: TComboBox;
Edit1: TEdit;
procedure RadioButton1Click(Sender: TObject);
procedure RadioButton2Click(Sender: TObject);
procedure RadioButton3Click(Sender: TObject);
private
{ Private declarations }
procedure IniStringGrid;
public
{ Public declarations }
end;
implementation
{$R *.dfm}
procedure TFrame_Sell.RadioButton1Click(Sender: TObject);
begin
Notebook1.PageIndex := 0;
end;
procedure TFrame_Sell.RadioButton2Click(Sender: TObject);
begin
Notebook1.PageIndex := 1;
ComboBox1.ItemIndex := -1;
ComboBox2.ItemIndex := -1;
end;
procedure TFrame_Sell.RadioButton3Click(Sender: TObject);
begin
Notebook1.PageIndex := 2;
end;
procedure TFrame_Sell.IniStringGrid;
var
i: integer;
begin
StringGrid1.ColWidths[5] := 0;
StringGrid1.ColWidths[6] := 0;
StringGrid1.Cells[0,0] := '作品名称';
StringGrid1.Cells[1,0] := '作品作者';
StringGrid1.Cells[2,0] := '出售价格';
StringGrid1.Cells[3,0] := '作品描述';
StringGrid1.Cells[4,0] := '编号';
for i := 1 to StringGrid1.RowCount -1 do
begin
StringGrid1.Cells[0,i] := '';
StringGrid1.Cells[1,i] := '';
StringGrid1.Cells[2,i] := '';
StringGrid1.Cells[3,i] := '';
StringGrid1.Cells[4,i] := '';
StringGrid1.Cells[5,i] := '';
StringGrid1.Cells[6,i] := '';
end;
StringGrid1.RowCount := 2;
end;
end.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -