?? unit6.pas
字號(hào):
unit Unit6;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ComCtrls;
type
TForm_car = class(TForm)
Label1: TLabel;
Label2: TLabel;
ListBox_d: TListBox;
ListBox_c: TListBox;
Label3: TLabel;
ListBox_r: TListBox;
Label4: TLabel;
Label5: TLabel;
MC_leave: TMonthCalendar;
Button1: TButton;
Label6: TLabel;
Edit_Major: TEdit;
Edit_School: TEdit;
procedure Button1Click(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form_car: TForm_car;
implementation
uses Unit2, Unit5, Unit1;
{$R *.dfm}
procedure TForm_car.Button1Click(Sender: TObject);
var
count_car2: integer;
begin
with DM do
begin
Table_car2.Active:=True;
count_car2:=Table_car2.RecordCount;
if Form1.Modify_car then
begin
Form1.Modify_car:=False;
end
else
begin
Table_car2.Append;
Table_car2.FieldByName('序號(hào)').AsString:=IntToStr(count_car2+1);
end;
Table_car2.FieldByName('職工號(hào)').AsString:=Table_basic.FieldValues['職工號(hào)'];
Table_car2.FieldByName('學(xué)歷').AsString:=ListBox_c.Items[ListBox_c.ItemIndex];
Table_car2.FieldByName('學(xué)位').AsString:=ListBox_d.Items[ListBox_d.ItemIndex];
Table_car2.FieldByName('學(xué)制').AsString:=ListBox_r.Items[ListBox_r.ItemIndex];
Table_car2.FieldByName('專業(yè)').AsString:=Edit_Major.Text;
Table_car2.FieldByName('院校').AsString:=Edit_School.Text;
Table_car2.FieldByName('畢業(yè)時(shí)間').AsDateTime:=MC_Leave.Date;
Table_car2.Post;
Table_car2.Refresh;
Table_car2.Active:=False;
Table_car.Refresh;
end;
Form_car.Hide;
end;
procedure TForm_car.FormClose(Sender: TObject; var Action: TCloseAction);
begin
with DM do
begin
Table_exp.Cancel;
Table_exp.Refresh;
end;
end;
end.
?? 快捷鍵說(shuō)明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -