897 lines
26 KiB
ObjectPascal
897 lines
26 KiB
ObjectPascal
unit U_FCDJSMCK;
|
||
|
||
interface
|
||
|
||
uses
|
||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
|
||
cxEdit, DB, cxDBData, StdCtrls, ExtCtrls, ADODB, DBClient,
|
||
cxGridCustomPopupMenu, cxGridPopupMenu, cxGridLevel, cxGridCustomTableView,
|
||
cxGridTableView, cxGridDBTableView, cxClasses, cxControls, cxGridCustomView,
|
||
cxGrid, MovePanel, cxCheckBox, Menus, ComCtrls, BtnEdit, ShellAPI, cxTextEdit,
|
||
cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxSkinsCore,
|
||
dxSkinsDefaultPainters, dxSkinscxPCPainter, dxSkinBlack, dxSkinBlue,
|
||
dxSkinBlueprint, dxSkinCaramel, dxSkinCoffee, dxSkinDarkRoom, dxSkinDarkSide,
|
||
dxSkinDevExpressDarkStyle, dxSkinDevExpressStyle, dxSkinFoggy,
|
||
dxSkinGlassOceans, dxSkinHighContrast, dxSkiniMaginary, dxSkinLilian,
|
||
dxSkinLiquidSky, dxSkinLondonLiquidSky, dxSkinMcSkin, dxSkinMetropolis,
|
||
dxSkinMetropolisDark, dxSkinMoneyTwins, dxSkinOffice2007Black,
|
||
dxSkinOffice2007Blue, dxSkinOffice2007Green, dxSkinOffice2007Pink,
|
||
dxSkinOffice2007Silver, dxSkinOffice2010Black, dxSkinOffice2010Blue,
|
||
dxSkinOffice2010Silver, dxSkinOffice2013DarkGray, dxSkinOffice2013LightGray,
|
||
dxSkinOffice2013White, dxSkinPumpkin, dxSkinSeven, dxSkinSevenClassic,
|
||
dxSkinSharp, dxSkinSharpPlus, dxSkinSilver, dxSkinSpringTime, dxSkinStardust,
|
||
dxSkinSummer2008, dxSkinTheAsphaltWorld, dxSkinValentine, dxSkinVS2010,
|
||
dxSkinWhiteprint, dxSkinXmas2008Blue, RM_Common, RM_Class, RM_GridReport,
|
||
RM_System, RM_Dataset;
|
||
|
||
type
|
||
TfrmFCDJSMCK = class(TForm)
|
||
ADOQueryTemp: TADOQuery;
|
||
ADOQueryCmd: TADOQuery;
|
||
DS_MainSel: TDataSource;
|
||
CDS_MainSel: TClientDataSet;
|
||
cxGridPopupMenu4: TcxGridPopupMenu;
|
||
cxGrid3: TcxGrid;
|
||
Tv3: TcxGridDBTableView;
|
||
cxGridDBColumn1: TcxGridDBColumn;
|
||
v3Column3: TcxGridDBColumn;
|
||
cxGridDBColumn4: TcxGridDBColumn;
|
||
v3Column1: TcxGridDBColumn;
|
||
cxGridLevel1: TcxGridLevel;
|
||
Panel2: TPanel;
|
||
Label5: TLabel;
|
||
Label4: TLabel;
|
||
Label9: TLabel;
|
||
CKOrdNo: TEdit;
|
||
BaoID: TEdit;
|
||
CRTime: TDateTimePicker;
|
||
KHName: TEdit;
|
||
Button2: TButton;
|
||
cxStyleRepository1: TcxStyleRepository;
|
||
cxStyle1: TcxStyle;
|
||
Label12: TLabel;
|
||
CDS_Main: TClientDataSet;
|
||
Button1: TButton;
|
||
v3Column2: TcxGridDBColumn;
|
||
Button3: TButton;
|
||
CKType: TComboBox;
|
||
Label1: TLabel;
|
||
edtIsSMTH: TEdit;
|
||
Label2: TLabel;
|
||
Button4: TButton;
|
||
CDS_DCK: TClientDataSet;
|
||
MovePanel2: TMovePanel;
|
||
v3Column4: TcxGridDBColumn;
|
||
Tv3Column1: TcxGridDBColumn;
|
||
Tv3Column2: TcxGridDBColumn;
|
||
Tv3Column3: TcxGridDBColumn;
|
||
Label3: TLabel;
|
||
FHWAYS: TComboBox;
|
||
Label6: TLabel;
|
||
CHENO: TEdit;
|
||
Button5: TButton;
|
||
ComboBox1: TComboBox;
|
||
CDS_HZ: TClientDataSet;
|
||
RMDBPRT: TRMDBDataSet;
|
||
RM3: TRMGridReport;
|
||
ClientDataSet1: TClientDataSet;
|
||
ADOQueryPrint: TADOQuery;
|
||
Tv3Column4: TcxGridDBColumn;
|
||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||
procedure FormDestroy(Sender: TObject);
|
||
procedure FormShow(Sender: TObject);
|
||
procedure BaoIDKeyPress(Sender: TObject; var Key: Char);
|
||
procedure Button2Click(Sender: TObject);
|
||
procedure Button1Click(Sender: TObject);
|
||
procedure Button3Click(Sender: TObject);
|
||
procedure CKTypeChange(Sender: TObject);
|
||
procedure edtIsSMTHClick(Sender: TObject);
|
||
procedure Button4Click(Sender: TObject);
|
||
procedure Tv3DblClick(Sender: TObject);
|
||
procedure Button5Click(Sender: TObject);
|
||
private
|
||
{ Private declarations }
|
||
FSMID, FCKOrdNo, FRKOrdID, FMJID, CZZT: string;
|
||
function JudgeSQD(): Boolean;
|
||
function JudgeRKD(): Boolean;
|
||
function JudgeJTM(): Boolean;
|
||
function JudgeRKDCX(): Boolean;
|
||
function JudgeJTMCX(): Boolean;
|
||
procedure SaveCKData();
|
||
procedure SaveCKDataJTM();
|
||
procedure SaveCKDataCX();
|
||
procedure SaveCKDataJTMCX();
|
||
procedure InitCKGrid();
|
||
public
|
||
{ Public declarations }
|
||
end;
|
||
|
||
var
|
||
frmFCDJSMCK: TfrmFCDJSMCK;
|
||
|
||
implementation
|
||
|
||
uses
|
||
U_DataLink, U_Fun, MMSystem, U_ZdyAttachment, U_ZdyAttachGYS,
|
||
U_CKProductBCPKCListSel, U_CPOutListSel;
|
||
|
||
{$R *.dfm}
|
||
function TfrmFCDJSMCK.JudgeSQD(): Boolean;
|
||
begin
|
||
Result := false;
|
||
try
|
||
if CKType.Text = '<27><><EFBFBD><EFBFBD><DEB3><EFBFBD>' then
|
||
begin
|
||
if Trim(KHName.Text) = '' then
|
||
raise Exception.Create('<27><>ѡ<EFBFBD><D1A1><EFBFBD>ջ<EFBFBD><D5BB><EFBFBD>λ!');
|
||
end;
|
||
|
||
if Trim(CKOrdNo.Text) = '' then
|
||
raise Exception.Create('δɨ<CEB4><C9A8><EFBFBD><EFBFBD><EFBFBD>뵥<EFBFBD><EBB5A5>ͣ<EFBFBD><CDA3><EFBFBD><EFBFBD>!');
|
||
|
||
Result := True;
|
||
except
|
||
Result := false;
|
||
MovePanel2.Visible := False;
|
||
application.MessageBox(PChar(Exception(ExceptObject).Message), '<27><>ʾ<EFBFBD><CABE>Ϣ', 0);
|
||
// PlaySound('δɨ<CEB4><C9A8><EFBFBD><EFBFBD><EFBFBD>뵥<EFBFBD><EBB5A5>ͣ<EFBFBD><CDA3><EFBFBD><EFBFBD>.wav', 0, SND_FILENAME or SND_ASYNC);
|
||
end;
|
||
end;
|
||
|
||
function TfrmFCDJSMCK.JudgeRKD(): Boolean;
|
||
begin
|
||
try
|
||
if CKType.Text = '<27><><EFBFBD><EFBFBD><DEB3><EFBFBD>' then
|
||
begin
|
||
if Trim(KHName.Text) = '' then
|
||
raise Exception.Create('<27><>ѡ<EFBFBD><D1A1><EFBFBD>ջ<EFBFBD><D5BB><EFBFBD>λ!');
|
||
end;
|
||
|
||
with ADOQueryTemp do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('select * from WFB_MJJY A ');
|
||
sql.Add('where RKOrdID=' + quotedstr(trim(FRKOrdID)));
|
||
Open;
|
||
end;
|
||
|
||
if ADOQueryTemp.IsEmpty then
|
||
raise Exception.Create('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͣ<EFBFBD><CDA3><EFBFBD><EFBFBD>!');
|
||
|
||
with ADOQueryTemp do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('SELECT RKOrdID,CKOrdNo FROM CK_BanCP_CR where CRFlag=''<27><><EFBFBD><EFBFBD>'' and RKOrdID=' + quotedstr(trim(FRKOrdID)));
|
||
Open;
|
||
end;
|
||
if not ADOQueryTemp.IsEmpty then
|
||
raise Exception.Create('<27><>ɨ<EFBFBD><C9A8>!');
|
||
|
||
Result := True;
|
||
except
|
||
Result := false;
|
||
application.MessageBox(PChar(Exception(ExceptObject).Message), '<27><>ʾ<EFBFBD><CABE>Ϣ', 0);
|
||
end;
|
||
end;
|
||
|
||
function TfrmFCDJSMCK.JudgeJTM(): Boolean;
|
||
begin
|
||
try
|
||
if CKType.Text = '<27><><EFBFBD><EFBFBD><DEB3><EFBFBD>' then
|
||
begin
|
||
if Trim(KHName.Text) = '' then
|
||
raise Exception.Create('<27><>ѡ<EFBFBD><D1A1><EFBFBD>ջ<EFBFBD><D5BB><EFBFBD>λ');
|
||
end;
|
||
with ADOQueryTemp do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('select MJID from WFB_MJJY where MJID=' + quotedstr(trim(FMJID)));
|
||
Open;
|
||
end;
|
||
if ADOQueryTemp.IsEmpty then
|
||
begin
|
||
raise Exception.Create('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͣ<EFBFBD><CDA3><EFBFBD><EFBFBD>');
|
||
end;
|
||
with ADOQueryTemp do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('select RKOrdID from CK_BanCP_CR where CRFlag=''<27><><EFBFBD><EFBFBD>'' and MJID=' + quotedstr(trim(FMJID)));
|
||
Open;
|
||
end;
|
||
if ADOQueryTemp.IsEmpty then
|
||
begin
|
||
raise Exception.Create('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>δ<EFBFBD><CEB4><EFBFBD><EFBFBD>');
|
||
end
|
||
else
|
||
begin
|
||
FRKOrdID := Trim(ADOQueryTemp.fieldbyname('RKOrdID').AsString);
|
||
end;
|
||
with ADOQueryTemp do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('SELECT RKOrdID,CKOrdNo FROM CK_BanCP_CR where CRFlag=''<27><><EFBFBD><EFBFBD>'' and MJID=' + quotedstr(trim(FMJID)));
|
||
Open;
|
||
end;
|
||
if ADOQueryTemp.IsEmpty = False then
|
||
begin
|
||
if Trim(ADOQueryTemp.fieldbyname('CKOrdNo').AsString) = Trim(CKOrdNo.Text) then
|
||
begin
|
||
raise Exception.Create('<27>ظ<EFBFBD>ɨ<EFBFBD><C9A8>');
|
||
end
|
||
else
|
||
begin
|
||
raise Exception.Create('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѳ<EFBFBD><D1B3><EFBFBD>');
|
||
end;
|
||
end;
|
||
|
||
Result := True;
|
||
except
|
||
Result := false;
|
||
// application.MessageBox(PChar(Exception(ExceptObject).Message), '<27><>ʾ<EFBFBD><CABE>Ϣ', 0);
|
||
PlaySound(PAnsiChar('wav\' + Exception(ExceptObject).Message + '.wav'), 0, SND_FILENAME or SND_ASYNC);
|
||
end;
|
||
end;
|
||
|
||
function TfrmFCDJSMCK.JudgeJTMCX(): Boolean;
|
||
begin
|
||
try
|
||
if Trim(CKOrdNo.Text) = '' then
|
||
raise Exception.Create('<27><><EFBFBD>ⵥ<EFBFBD>Ų<EFBFBD><C5B2><EFBFBD>Ϊ<EFBFBD><CEAA>!');
|
||
|
||
if CDS_MainSel.IsEmpty then
|
||
raise Exception.Create('<27>ɳ<DEBF><C9B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>!');
|
||
|
||
with ADOQueryTemp do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('SELECT RKOrdID,CKOrdNo FROM CK_BanCP_CR where CRFlag=''<27><><EFBFBD><EFBFBD>'' and MJID=' + quotedstr(FMJID));
|
||
Open;
|
||
end;
|
||
|
||
if ADOQueryTemp.IsEmpty then
|
||
raise Exception.Create('<27>ɳ<DEBF><C9B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>!');
|
||
|
||
Result := True;
|
||
except
|
||
Result := false;
|
||
MovePanel2.Visible := False;
|
||
application.MessageBox(PChar(Exception(ExceptObject).Message), '<27><>ʾ<EFBFBD><CABE>Ϣ', 0);
|
||
end;
|
||
end;
|
||
|
||
function TfrmFCDJSMCK.JudgeRKDCX(): Boolean;
|
||
begin
|
||
try
|
||
if Trim(CKOrdNo.Text) = '' then
|
||
raise Exception.Create('<27><><EFBFBD>ⵥ<EFBFBD>Ų<EFBFBD><C5B2><EFBFBD>Ϊ<EFBFBD><CEAA>!');
|
||
|
||
if CDS_MainSel.IsEmpty then
|
||
raise Exception.Create('<27>ɳ<DEBF><C9B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>!');
|
||
|
||
with ADOQueryTemp do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('SELECT RKOrdID,CKOrdNo FROM CK_BanCP_CR where CRFlag=''<27><><EFBFBD><EFBFBD>'' and CKOrdNo=' + quotedstr(FCKOrdNo));
|
||
Open;
|
||
end;
|
||
|
||
if ADOQueryTemp.IsEmpty then
|
||
raise Exception.Create('<27>ɳ<DEBF><C9B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>!');
|
||
|
||
Result := True;
|
||
except
|
||
Result := false;
|
||
application.MessageBox(PChar(Exception(ExceptObject).Message), '<27><>ʾ<EFBFBD><CABE>Ϣ', 0);
|
||
end;
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.SaveCKData();
|
||
begin
|
||
try
|
||
ADOQueryCmd.Connection.BeginTrans;
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('UPDATE CK_BanCP_CKList Set CKDate=getdate() ');
|
||
sql.Add(',KHNmae= ' + Quotedstr(KHName.Text));
|
||
sql.Add(',CKType= ' + Quotedstr(CKType.Text));
|
||
sql.Add('where CKOrdNo=' + Quotedstr(FCKOrdNo));
|
||
ExecSQL;
|
||
end;
|
||
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('UPDATE CK_BanCP_CR Set ');
|
||
sql.add(' CRTime=getdate(),CRType=''ɨ<><C9A8><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'',CRFlag=''<27><><EFBFBD><EFBFBD>'' ');
|
||
sql.add(',CKOrdNo=' + Quotedstr(FCKOrdNo));
|
||
sql.add(',RKOrdID=' + Quotedstr(FRKOrdID));
|
||
sql.Add(' where exists(select MJID from CK_BanCP_CR X where CK_BanCP_CR.MJID=X.MJID and X.CRFlag=''<27><><EFBFBD><EFBFBD>'' and X.RKOrdID=' + Quotedstr(FRKOrdID) + ') ');
|
||
sql.Add('and CK_BanCP_CR.CRFlag=''<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'' ');
|
||
ExecSQL;
|
||
end;
|
||
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('UPDATE CK_BanCP_KC Set ');
|
||
sql.add(' KCValid=''N'' ');
|
||
sql.Add(' where exists(select MJID from CK_BanCP_CR X where CK_BanCP_KC.MJID=X.MJID and X.CRFlag=''<27><><EFBFBD><EFBFBD>'' and X.RKOrdID=' + Quotedstr(FRKOrdID) + ') ');
|
||
ExecSQL;
|
||
end;
|
||
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('UPDATE WFB_MJJY Set MJStr2=''<27>ѳ<EFBFBD><D1B3><EFBFBD>'' ');
|
||
sql.Add(' where exists (select MJID from CK_BanCP_CR X where WFB_MJJY.MJID=X.MJID and X.CRFlag=''<27><><EFBFBD><EFBFBD>'' and X.RKOrdID=' + Quotedstr(FRKOrdID) + ') ');
|
||
SQL.Add(' and WFB_MJJY.MJStr2=''<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'' ');
|
||
ExecSQL;
|
||
end;
|
||
|
||
ADOQueryCmd.Connection.CommitTrans;
|
||
PlaySound('wav\<5C><>ȷ.wav', 0, SND_FILENAME or SND_ASYNC);
|
||
except
|
||
ADOQueryCmd.Connection.RollbackTrans;
|
||
application.MessageBox('<27><><EFBFBD><EFBFBD>ʧ<EFBFBD>ܣ<EFBFBD>', '<27><>ʾ<EFBFBD><CABE>Ϣ', 0);
|
||
end;
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.SaveCKDataJTM();
|
||
begin
|
||
try
|
||
ADOQueryCmd.Connection.BeginTrans;
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('UPDATE CK_BanCP_CKList Set CKDate=' + quotedstr(FormatDateTime('yyyy-MM-dd', CRTime.DateTime)));
|
||
sql.Add(',KHNmae= ' + Quotedstr(KHName.Text));
|
||
sql.Add(',CKType= ' + Quotedstr(CKType.Text));
|
||
sql.Add('where CKOrdNo=' + Quotedstr(FCKOrdNo));
|
||
ExecSQL;
|
||
end;
|
||
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('UPDATE CK_BanCP_CR Set ');
|
||
sql.add(' CRTime=' + quotedstr(FormatDateTime('yyyy-MM-dd', CRTime.DateTime)) + ',CRType=''ɨ<><C9A8><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'',CRFlag=''<27><><EFBFBD><EFBFBD>'' ');
|
||
sql.add(',CKOrdNo=' + Quotedstr(FCKOrdNo));
|
||
sql.add(',RKOrdID=' + Quotedstr(FRKOrdID));
|
||
SQL.ADD(',FILLTIME=GETDATE()');
|
||
sql.Add(' where CK_BanCP_CR.MJID=' + Quotedstr(Trim(FMJID)));
|
||
sql.Add('and CK_BanCP_CR.CRFlag=''<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'' ');
|
||
ExecSQL;
|
||
end;
|
||
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('UPDATE CK_BanCP_KC Set ');
|
||
sql.add(' KCValid=''N'' ');
|
||
sql.Add(' where CK_BanCP_KC.MJID=' + Quotedstr(Trim(FMJID)));
|
||
ExecSQL;
|
||
end;
|
||
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('UPDATE WFB_MJJY Set MJStr2=''<27>ѳ<EFBFBD><D1B3><EFBFBD>'' ');
|
||
sql.Add(' where WFB_MJJY.MJID=' + Quotedstr(Trim(FMJID)));
|
||
SQL.Add(' and WFB_MJJY.MJStr2=''<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'' ');
|
||
ExecSQL;
|
||
end;
|
||
PlaySound('wav\<5C><>ȷ.wav', 0, SND_FILENAME or SND_ASYNC);
|
||
ADOQueryCmd.Connection.CommitTrans;
|
||
except
|
||
ADOQueryCmd.Connection.RollbackTrans;
|
||
MovePanel2.Visible := False;
|
||
MovePanel2.Visible := False;
|
||
application.MessageBox('<27><><EFBFBD><EFBFBD>ʧ<EFBFBD>ܣ<EFBFBD>', '<27><>ʾ<EFBFBD><CABE>Ϣ', 0);
|
||
end;
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.SaveCKDataCX();
|
||
begin
|
||
try
|
||
ADOQueryCmd.Connection.BeginTrans;
|
||
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('Update CK_BanCP_CR Set CRFlag=''<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'',CRType='''',CRTime=NULL,CRNote='''',CKOrdNo='''' ');
|
||
sql.Add(' where exists(select MJID from CK_BanCP_CR X where CK_BanCP_CR.MJID=X.MJID and X.CRFlag=''<27><><EFBFBD><EFBFBD>'' and X.RKOrdID=' + Quotedstr(FRKOrdID) + ') ');
|
||
sql.Add(' and CRFlag=''<27><><EFBFBD><EFBFBD>''');
|
||
|
||
sql.Add(' UPdate CK_BanCP_KC Set KCValid=''Y'' ');
|
||
sql.Add(' where exists(select MJID from CK_BanCP_CR X where CK_BanCP_KC.MJID=X.MJID and X.CRFlag=''<27><><EFBFBD><EFBFBD>'' and X.RKOrdID=' + Quotedstr(FRKOrdID) + ') ');
|
||
sql.Add(' and KCValid=''N'' ');
|
||
|
||
sql.Add(' Update WFB_MJJY Set MJStr2=''<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'' ');
|
||
sql.Add(' where exists (select MJID from CK_BanCP_CR X where WFB_MJJY.MJID=X.MJID and X.CRFlag=''<27><><EFBFBD><EFBFBD>'' and X.RKOrdID=' + Quotedstr(FRKOrdID) + ') ');
|
||
SQL.Add(' and WFB_MJJY.MJStr2=''<27>ѳ<EFBFBD><D1B3><EFBFBD>'' ');
|
||
ExecSQL;
|
||
end;
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('insert into SY_SysLog(operor,opertime,Model,acction,opevent,result) values( ');
|
||
sql.Add(' ' + quotedstr(trim(DName)));
|
||
sql.Add(',getdate() ');
|
||
sql.Add(',' + quotedstr(''));
|
||
sql.Add(',' + quotedstr(trim('<27><><EFBFBD><EFBFBD>ɨ<EFBFBD>賷<EFBFBD><E8B3B7>')));
|
||
sql.Add(',' + quotedstr('<27><><EFBFBD>ⵥ<EFBFBD>ţ<EFBFBD>' + trim(FRKOrdID) + ' <20><><EFBFBD>ⵥ<EFBFBD>ţ<EFBFBD>' + trim(FCKOrdNo)));
|
||
sql.Add(',' + quotedstr(trim('<27>ɹ<EFBFBD>')));
|
||
sql.Add(')');
|
||
ExecSQL;
|
||
end;
|
||
ADOQueryCmd.Connection.CommitTrans;
|
||
PlaySound('wav\<5C><>ȷ.wav', 0, SND_FILENAME or SND_ASYNC);
|
||
except
|
||
ADOQueryCmd.Connection.RollbackTrans;
|
||
application.MessageBox('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʧ<EFBFBD>ܣ<EFBFBD>', '<27><>ʾ<EFBFBD><CABE>Ϣ', 0);
|
||
end;
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.SaveCKDataJTMCX();
|
||
begin
|
||
try
|
||
ADOQueryCmd.Connection.BeginTrans;
|
||
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('Update CK_BanCP_CR Set CRFlag=''<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'',CRType='''',CRTime=NULL,CRNote='''',CKOrdNo='''' ');
|
||
sql.Add(' where CK_BanCP_CR.MJID=' + Quotedstr(Trim(FMJID)));
|
||
sql.Add(' and CRFlag=''<27><><EFBFBD><EFBFBD>''');
|
||
|
||
sql.Add(' UPdate CK_BanCP_KC Set KCValid=''Y'' ');
|
||
sql.Add(' where CK_BanCP_KC.MJID=' + Quotedstr(Trim(FMJID)));
|
||
sql.Add(' and KCValid=''N'' ');
|
||
|
||
sql.Add(' Update WFB_MJJY Set MJStr2=''<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'' ');
|
||
sql.Add(' where WFB_MJJY.MJID=' + Quotedstr(Trim(FMJID)));
|
||
SQL.Add(' and WFB_MJJY.MJStr2=''<27>ѳ<EFBFBD><D1B3><EFBFBD>'' ');
|
||
ExecSQL;
|
||
end;
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('insert into SY_SysLog(operor,opertime,Model,acction,opevent,result) values( ');
|
||
sql.Add(' ' + quotedstr(trim(DName)));
|
||
sql.Add(',getdate() ');
|
||
sql.Add(',' + quotedstr(''));
|
||
sql.Add(',' + quotedstr(trim('<27><><EFBFBD><EFBFBD>ɨ<EFBFBD>賷<EFBFBD><E8B3B7>')));
|
||
sql.Add(',' + quotedstr('<27><><EFBFBD><EFBFBD><EFBFBD>룺' + trim(FMJID) + ' <20><><EFBFBD>ⵥ<EFBFBD>ţ<EFBFBD>' + trim(FCKOrdNo)));
|
||
sql.Add(',' + quotedstr(trim('<27>ɹ<EFBFBD>')));
|
||
sql.Add(')');
|
||
ExecSQL;
|
||
end;
|
||
PlaySound('wav\<5C><>ȷ.wav', 0, SND_FILENAME or SND_ASYNC);
|
||
ADOQueryCmd.Connection.CommitTrans;
|
||
except
|
||
ADOQueryCmd.Connection.RollbackTrans;
|
||
application.MessageBox('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʧ<EFBFBD>ܣ<EFBFBD>', '<27><>ʾ<EFBFBD><CABE>Ϣ', 0);
|
||
end;
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.InitCKGrid();
|
||
begin
|
||
with ADOQueryTemp do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('select AA.*, B.OrderNo,B.MPRTCode,B.MPRTCodeName,B.MPRTSpec,B.MPRTMF,B.MPRTKZ ,b.zhaiyao,C.PRTColor,C.PRTEColor,C.PRTHX,C.PrtKuanNo,b.conno ');
|
||
sql.Add('from (select count(A.SubId) ps,SUM(A.KGQty) KGQty,SUM(A.Qty+ISNULL(ZKOUMI,0)) Qty,SUM(A.NetKGQty) NetKGQty,MJCD=SUM(A.QTY)');
|
||
sql.Add(',A.MainId,A.SubId,A.QtyUnit,A.CPType,A.JYXH,A.APID,A.jycolor');
|
||
sql.Add('from CK_BanCP_CR A INNER JOIN WFB_MJJY B ON A.MJID=B.MJID where A.CRFlag=''<27><><EFBFBD><EFBFBD>'' and CKOrdNo=' + quotedstr(FCKOrdNo));
|
||
sql.Add('group by A.jycolor,A.MainId,A.SubId,A.QtyUnit,A.CPType,A.JYXH,A.APID ) AA inner join JYOrder_Main B on AA.MainId=B.MainId');
|
||
sql.Add(' inner join JYOrder_Sub C on AA.SubId=C.SubId ');
|
||
// ShowMessage(SQL.Text);
|
||
Open;
|
||
end;
|
||
SCreateCDS20(ADOQueryTemp, CDS_MainSel);
|
||
SInitCDSData20(ADOQueryTemp, CDS_MainSel);
|
||
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.FormClose(Sender: TObject; var Action: TCloseAction);
|
||
begin
|
||
Action := caFree;
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.FormDestroy(Sender: TObject);
|
||
begin
|
||
frmFCDJSMCK := nil;
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.FormShow(Sender: TObject);
|
||
begin
|
||
BaoID.SetFocus;
|
||
ReadCxGrid('ɨ<><C9A8><EFBFBD><EFBFBD><EFBFBD><EFBFBD>', Tv3, '<27><><EFBFBD><EFBFBD><EFBFBD>ֿ<EFBFBD>');
|
||
CRTime.DateTime := SGetServerDate(ADOQueryTemp);
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.BaoIDKeyPress(Sender: TObject; var Key: Char);
|
||
begin
|
||
|
||
if Key = #13 then
|
||
begin
|
||
MovePanel2.Visible := True;
|
||
MovePanel2.Refresh;
|
||
FSMID := TRIM(BaoID.Text);
|
||
BaoID.Text := '';
|
||
FCKOrdNo := Trim(CKOrdNo.text);
|
||
FRKOrdID := '';
|
||
FMJID := '';
|
||
if edtIsSMTH.Text = '' then
|
||
begin
|
||
if not JudgeSQD() then//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ⵥ
|
||
exit;
|
||
|
||
if Copy(FSMID, 1, 2) = 'YK' then
|
||
begin
|
||
with ADOQueryTemp do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add(' select MJID from WFB_MJJY where MJStr2=''<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'' and APID=' + quotedstr(FSMID));
|
||
Open;
|
||
end;
|
||
SCreateCDS20(ADOQueryTemp, CDS_DCK);
|
||
SInitCDSData20(ADOQueryTemp, CDS_DCK);
|
||
|
||
while not CDS_DCK.IsEmpty do
|
||
begin
|
||
FMJID := Trim(CDS_DCK.fieldbyname('MJID').AsString);
|
||
if JudgeJTM() then //<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||
SaveCKDataJTM();
|
||
CDS_DCK.Delete;
|
||
end;
|
||
end
|
||
else
|
||
begin
|
||
FMJID := FSMID;
|
||
if JudgeJTM() then //<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||
SaveCKDataJTM();
|
||
end;
|
||
end
|
||
else
|
||
begin
|
||
FMJID := FSMID;
|
||
if JudgeJTMCX() then //<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||
SaveCKDataJTMCX();
|
||
end;
|
||
MovePanel2.Visible := False;
|
||
// if CZZT <> 'ѡ<><D1A1><EFBFBD><EFBFBD><EFBFBD><EFBFBD>' then
|
||
InitCKGrid();
|
||
end;
|
||
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.Button2Click(Sender: TObject);
|
||
begin
|
||
Close;
|
||
WriteCxGrid('ɨ<><C9A8><EFBFBD><EFBFBD><EFBFBD><EFBFBD>', Tv3, '<27><><EFBFBD><EFBFBD><EFBFBD>ֿ<EFBFBD>');
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.Button1Click(Sender: TObject);
|
||
begin
|
||
if CKType.Text = '<27><><EFBFBD>۳<EFBFBD><DBB3><EFBFBD>' then
|
||
begin
|
||
try
|
||
frmZdyAttachment := TfrmZdyAttachment.Create(Application);
|
||
with frmZdyAttachment do
|
||
begin
|
||
|
||
if ShowModal = 1 then
|
||
begin
|
||
KHName.Text := Trim(CDS_HZ.fieldbyname('CoName').AsString);
|
||
end;
|
||
end;
|
||
finally
|
||
frmZdyAttachment.Free;
|
||
end;
|
||
end
|
||
else
|
||
begin
|
||
try
|
||
frmZdyAttachGYS := TfrmZdyAttachGYS.Create(Application);
|
||
with frmZdyAttachGYS do
|
||
begin
|
||
|
||
if ShowModal = 1 then
|
||
begin
|
||
KHName.Text := Trim(CDS_HZ.fieldbyname('CoName').AsString);
|
||
|
||
end;
|
||
end;
|
||
finally
|
||
frmZdyAttachGYS.Free;
|
||
end;
|
||
end;
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.Button3Click(Sender: TObject);
|
||
begin
|
||
if KHName.Text = '' then
|
||
begin
|
||
Application.MessageBox('<27><><EFBFBD><EFBFBD>ѡ<EFBFBD><D1A1><EFBFBD>ջ<EFBFBD><D5BB><EFBFBD>λ<EFBFBD><CEBB>', '<27><>ʾ', 0);
|
||
exit;
|
||
end;
|
||
if GetLSNo(ADOQueryTemp, FCKOrdNo, 'KL', 'CK_BanCP_CR', 4, 1) = False then
|
||
begin
|
||
Application.MessageBox('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ˮ<EFBFBD><CBAE><EFBFBD>쳣<EFBFBD><ECB3A3>', '<27><>ʾ', 0);
|
||
exit;
|
||
end;
|
||
CKOrdNo.TEXT := FCKOrdNo;
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('insert into CK_BanCP_CKList(CKOrdNo) ');
|
||
sql.add('values(' + quotedstr(FCKOrdNo) + ') ');
|
||
ExecSQL;
|
||
end;
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.CKTypeChange(Sender: TObject);
|
||
begin
|
||
KHName.Text := '';
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.edtIsSMTHClick(Sender: TObject);
|
||
begin
|
||
BaoID.SetFocus;
|
||
if edtIsSMTH.Text = '<27><>' then
|
||
begin
|
||
edtIsSMTH.Text := '';
|
||
end
|
||
else
|
||
begin
|
||
if Application.MessageBox('ȷ<><C8B7>Ҫɨ<D2AA><C9A8><EFBFBD>˻<EFBFBD><CBBB><EFBFBD><EFBFBD><EFBFBD>', '<27><>ʾ', 32 + 4) = IDYES then
|
||
edtIsSMTH.Text := '<27><>';
|
||
end;
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.Button4Click(Sender: TObject);
|
||
var
|
||
MKey: Char;
|
||
SqlMJID: string;
|
||
begin
|
||
|
||
if Trim(CKOrdNo.Text) = '' then
|
||
begin
|
||
Application.MessageBox('<27><><EFBFBD>ⵥ<EFBFBD>Ų<EFBFBD><C5B2><EFBFBD>Ϊ<EFBFBD>գ<EFBFBD>', '<27><>ʾ', 0);
|
||
exit;
|
||
end;
|
||
|
||
if Trim(KHName.Text) = '' then
|
||
begin
|
||
Application.MessageBox('<27>ͻ<EFBFBD><CDBB><EFBFBD><EFBFBD>Ʋ<EFBFBD><C6B2><EFBFBD>Ϊ<EFBFBD>գ<EFBFBD>', '<27><>ʾ', 0);
|
||
exit;
|
||
end;
|
||
|
||
MKey := #13;
|
||
CZZT := 'ѡ<><D1A1><EFBFBD><EFBFBD><EFBFBD><EFBFBD>';
|
||
SqlMJID := '';
|
||
// try
|
||
// frmCKProductBCPKCListSel := TfrmCKProductBCPKCListSel.Create(Application);
|
||
// with frmCKProductBCPKCListSel do
|
||
// begin
|
||
// CustomerNoName.text := trim(Self.KHName.text);
|
||
// if ShowModal = 1 then
|
||
// begin
|
||
// with frmCKProductBCPKCListSel.CDS_Main do
|
||
// begin
|
||
// First;
|
||
// while not Eof do
|
||
// begin
|
||
// if Fieldbyname('ssel').AsBoolean then
|
||
// begin
|
||
// BaoID.Text := Trim(Fieldbyname('MJID').AsString);
|
||
// BaoIDKeyPress(BaoID, MKey);
|
||
// Sleep(200);
|
||
// end;
|
||
// Next;
|
||
// end;
|
||
// end;
|
||
// end;
|
||
// end;
|
||
// finally
|
||
// frmCKProductBCPKCListSel.Free;
|
||
// end;
|
||
// InitCKGrid();
|
||
|
||
try
|
||
frmCKProductBCPKCListSel := TfrmCKProductBCPKCListSel.Create(Application);
|
||
with frmCKProductBCPKCListSel do
|
||
begin
|
||
CustomerNoName.text := trim(Self.KHName.text);
|
||
if ShowModal = 1 then
|
||
begin
|
||
with frmCKProductBCPKCListSel.CDS_Main do
|
||
begin
|
||
First;
|
||
while not Eof do
|
||
begin
|
||
if Fieldbyname('ssel').AsBoolean then
|
||
begin
|
||
if Trim(SqlMJID) = '' then
|
||
SqlMJID := (Trim(fieldbyname('MJID').AsString))
|
||
else
|
||
SqlMJID := SqlMJID + ',' + (Trim(fieldbyname('MJID').AsString));
|
||
|
||
// BaoID.Text := Trim(Fieldbyname('MJID').AsString);
|
||
// BaoIDKeyPress(BaoID, MKey);
|
||
// Sleep(200);
|
||
end;
|
||
Next;
|
||
end;
|
||
if Trim(SqlMJID) = '' then
|
||
begin
|
||
Exit;
|
||
end;
|
||
// SqlMJID := 'MJID IN (' + SqlMJID + ')';
|
||
|
||
with ADOQueryCmd do
|
||
begin
|
||
Close;
|
||
sql.Clear;
|
||
sql.Add('UPDATE CK_BanCP_CKList Set CKDate=' + quotedstr(FormatDateTime('yyyy-MM-dd', CRTime.DateTime)));
|
||
sql.Add(',KHNmae= ' + Quotedstr(KHName.Text));
|
||
sql.Add(',CKType= ' + Quotedstr(CKType.Text));
|
||
sql.Add(',FHWAYS= ' + Quotedstr(FHWAYS.Text));
|
||
sql.Add(',CHENO= ' + Quotedstr(CHENO.Text));
|
||
sql.Add('where CKOrdNo=' + Quotedstr(FCKOrdNo));
|
||
|
||
sql.Add('UPDATE CK_BanCP_CR Set ');
|
||
sql.add(' CRTime=' + quotedstr(FormatDateTime('yyyy-MM-dd', CRTime.DateTime)) + ',CRType=''ɨ<><C9A8><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'',CRFlag=''<27><><EFBFBD><EFBFBD>'' ');
|
||
sql.add(',CKOrdNo=' + Quotedstr(FCKOrdNo));
|
||
sql.add(',RKOrdID=' + Quotedstr(FRKOrdID));
|
||
// sql.Add('where ' + SqlMJID);
|
||
SQL.ADD('WHERE EXISTS (select SP.RTValue from [dbo].[F_Tool_SplitString]( ' + quotedstr(SqlMJID));
|
||
sql.add(','','') SP where SP.RTValue=CK_BanCP_CR.MJID )');
|
||
sql.Add('and CK_BanCP_CR.CRFlag=''<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'' ');
|
||
|
||
sql.Add('UPDATE CK_BanCP_KC Set ');
|
||
sql.add(' KCValid=''N'' ');
|
||
SQL.ADD('WHERE EXISTS (select SP.RTValue from [dbo].[F_Tool_SplitString]( ' + quotedstr(SqlMJID));
|
||
sql.add(','','') SP where SP.RTValue=CK_BanCP_KC.MJID )');
|
||
|
||
sql.Add('UPDATE WFB_MJJY Set MJStr2=''<27>ѳ<EFBFBD><D1B3><EFBFBD>'' ');
|
||
SQL.ADD('WHERE EXISTS (select SP.RTValue from [dbo].[F_Tool_SplitString]( ' + quotedstr(SqlMJID));
|
||
sql.add(','','') SP where SP.RTValue=WFB_MJJY.MJID )');
|
||
SQL.Add(' and WFB_MJJY.MJStr2=''<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'' ');
|
||
|
||
ExecSQL;
|
||
end;
|
||
|
||
end;
|
||
end;
|
||
end;
|
||
finally
|
||
frmCKProductBCPKCListSel.Free;
|
||
end;
|
||
InitCKGrid();
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.Tv3DblClick(Sender: TObject);
|
||
begin
|
||
if CDS_MainSel.IsEmpty then
|
||
Exit;
|
||
try
|
||
frmCPOutListSel := TfrmCPOutListSel.Create(Application);
|
||
with frmCPOutListSel do
|
||
begin
|
||
CkOrdNo.text := trim(Self.CKOrdNo.text);
|
||
apid.text := Trim(Self.CDS_MainSel.fieldbyname('apid').AsString);
|
||
if ShowModal = 1 then
|
||
begin
|
||
InitCKGrid();
|
||
end;
|
||
end;
|
||
finally
|
||
frmCPOutListSel.Free;
|
||
end;
|
||
end;
|
||
|
||
procedure TfrmFCDJSMCK.Button5Click(Sender: TObject);
|
||
var
|
||
fPrintFile: string;
|
||
Txt, fImagePath: string;
|
||
Moudle: THandle;
|
||
Makebar: TMakebar;
|
||
Mixtext: TMixtext;
|
||
fckorderno: string;
|
||
// kj,kjw:DOUBLE;
|
||
begin
|
||
|
||
ExportFtErpFile(ComboBox1.Text + '.rmf', ADOQueryTemp);
|
||
|
||
with CDS_Main do
|
||
begin
|
||
|
||
if (ComboBox1.Text = '<27><>Ʒ<EFBFBD><C6B7><EFBFBD>ⷢ<EFBFBD><E2B7A2><EFBFBD>뵥') then
|
||
begin
|
||
with ADOQueryPrint do
|
||
begin
|
||
Close;
|
||
SQL.Clear;
|
||
sql.Add(' exec P_Print_CKMD ');
|
||
SQL.Add(' @DCODE=''' + Trim(Trim(CKORDNO.TEXT)) + '''');
|
||
|
||
Open;
|
||
end;
|
||
SCreateCDS20(ADOQueryPrint, CDS_HZ);
|
||
SInitCDSData20(ADOQueryPrint, CDS_HZ);
|
||
with ADOQueryPrint do
|
||
begin
|
||
Close;
|
||
SQL.Clear;
|
||
sql.Add(' exec P_Print_CKMD_hz ');
|
||
SQL.Add(' @DCODE=''' + Trim(Trim(CKORDNO.TEXT)) + '''');
|
||
|
||
Open;
|
||
end;
|
||
|
||
end;
|
||
try
|
||
Moudle := LoadLibrary('MakeQRBarcode.dll');
|
||
@Makebar := GetProcAddress(Moudle, 'Make');
|
||
@Mixtext := GetProcAddress(Moudle, 'MixText');
|
||
Txt := Trim(CKORDNO.TEXT);
|
||
fImagePath := ExtractFilePath(Application.ExeName) + 'image\temp.bmp';
|
||
if not DirectoryExists(pchar(ExtractFilePath(Application.ExeName) + 'image')) then
|
||
CreateDirectory(pchar(ExtractFilePath(Application.ExeName) + 'image'), nil);
|
||
if FileExists(fImagePath) then
|
||
DeleteFile(fImagePath);
|
||
Makebar(pchar(Txt), Length(Txt), 3, 3, 0, PChar(fImagePath), 3);
|
||
except
|
||
application.MessageBox('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʧ<EFBFBD>ܣ<EFBFBD>', '<27><>ʾ<EFBFBD><CABE>Ϣ', MB_ICONERROR);
|
||
exit;
|
||
end;
|
||
RM3.PreviewButtons := [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, pbExport, pbNavigator];
|
||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\' + ComboBox1.Text + '.rmf';
|
||
if FileExists(fPrintFile) then
|
||
begin
|
||
RMVariables['QRBARCODE'] := fImagePath;
|
||
RMVariables['DMR'] := Trim(DName);
|
||
|
||
RMVariables['RKOrdID'] := Trim(CKORDNO.TEXT);
|
||
RM3.LoadFromFile(fPrintFile);
|
||
|
||
RM3.ShowReport;
|
||
end
|
||
else
|
||
begin
|
||
Application.MessageBox(PChar('û<><C3BB><EFBFBD><EFBFBD>' + fPrintFile), '<27><>ʾ', 0);
|
||
Exit;
|
||
end;
|
||
|
||
end;
|
||
end;
|
||
|
||
end.
|
||
|