am_ajbj_rks.pas
资源名称:挡案管理系统.rar [点击查看]
上传用户:szruida
上传日期:2007-06-01
资源大小:6518k
文件大小:3k
源码类别:
Delphi控件源码
开发平台:
Delphi
- unit am_ajbj_rks;
- interface
- uses
- Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
- Dialogs, DB, ImgList, DBCtrlsEh, StdCtrls, DBCtrls, DBLookupEh, Mask,
- Buttons, ExtCtrls;
- type
- Tam_ajgl_rk = class(TForm)
- Panel2: TPanel;
- Panel1: TPanel;
- Label1: TLabel;
- Label2: TLabel;
- Label3: TLabel;
- Label4: TLabel;
- Label5: TLabel;
- Label6: TLabel;
- Label7: TLabel;
- Label8: TLabel;
- Label9: TLabel;
- Label10: TLabel;
- Label11: TLabel;
- Label12: TLabel;
- Label13: TLabel;
- Label14: TLabel;
- Label15: TLabel;
- Label16: TLabel;
- Label17: TLabel;
- Label18: TLabel;
- Label19: TLabel;
- Label20: TLabel;
- Label21: TLabel;
- Label22: TLabel;
- Label23: TLabel;
- Label24: TLabel;
- Label25: TLabel;
- DBEdit3: TDBEdit;
- DBEdit4: TDBEdit;
- DBEdit5: TDBEdit;
- DBEdit6: TDBEdit;
- DBEdit9: TDBEdit;
- DBEdit11: TDBEdit;
- DBEdit14: TDBEdit;
- DBEdit16: TDBEdit;
- DBEdit17: TDBEdit;
- DBLookupComboboxEh1: TDBLookupComboboxEh;
- DBLookupComboboxEh2: TDBLookupComboboxEh;
- DBLookupComboboxEh3: TDBLookupComboboxEh;
- DBMemo1: TDBMemo;
- DBMemo2: TDBMemo;
- DBMemo3: TDBMemo;
- DBEditEh1: TDBEditEh;
- DBEditEh3: TDBEditEh;
- DBEditEh4: TDBEditEh;
- DBEditEh5: TDBEditEh;
- DBEditEh2: TDBEditEh;
- DBEditEh6: TDBEditEh;
- DBLookupComboboxEh4: TDBLookupComboboxEh;
- ImageList1: TImageList;
- ds_ajgl: TDataSource;
- Save: TSpeedButton;
- Dele: TSpeedButton;
- procedure FormClose(Sender: TObject; var Action: TCloseAction);
- procedure SaveClick(Sender: TObject);
- procedure DeleClick(Sender: TObject);
- private
- { Private declarations }
- public
- { Public declarations }
- end;
- var
- am_ajgl_rk: Tam_ajgl_rk;
- implementation
- uses DMs, Am_gdajs;
- {$R *.dfm}
- procedure Tam_ajgl_rk.FormClose(Sender: TObject; var Action: TCloseAction);
- begin
- action:=cafree;
- am_ajgl_rk:=nil;
- end;
- procedure Tam_ajgl_rk.SaveClick(Sender: TObject);
- var s_kwdm,s_kwmc,s2,zcg_s:string;
- begin
- zcg_s:=dm.Am_ajgl.fieldbyname('aj_xh').AsString;//取当前序号
- s2:=dm.Am_ajgl.fieldbyname('ajlb_dm').AsString;//当前树节点的案卷类别代码
- if dblookupcomboboxeh4.Text='' then
- begin
- application.MessageBox('请选择库位','提示',mb_ok+mb_iconinformation);
- exit;
- end;
- s_kwdm:=dblookupcomboboxeh4.Value;//库位代码
- s_kwmc:=dbLookUPComboboxeh4.text;//库位名称
- dm.am_ajgl.Close;
- dm.am_ajgl.CommandText:='update am_ajgl set ajzt_mc=''入库案卷'',aj_bzjsrq=getdate(),kw_dm='+''''+s_kwdm+''''+',aj_kwmc='+''''+s_kwmc+''''+' where aj_xh='+''''+zcg_s+''''+'';
- dm.Am_ajgl.Execute;
- dm.Am_ajgl.Close;
- dm.am_ajgl.CommandText:='select * from am_ajgl';
- dm.am_ajgl.Open;
- application.MessageBox('入库成功','提示',mb_ok+mb_iconinformation);
- dm.V_AJGD.Close;
- dm.V_AJGD.CommandText:='select * from v_Ajgd where ajlb_dm='+''''+s2+''''+'';
- dm.v_ajgd.Open;
- close;
- end;
- procedure Tam_ajgl_rk.DeleClick(Sender: TObject);
- begin
- Close;
- end;
- end.