S
swean_98
Unregistered / Unconfirmed
GUEST, unregistred user!
以下代码中,Temp返回值始终为0,问题出在什么地方?请高人指教!
procedure TFrmDataFeed.BTNGenerateClick(Sender: TObject);
var
FileName,StartDate,EndDate:string;
Temp:Integer;
begin
if SDDataFeed.Execute then
begin
FileName:=SDDataFeed.FileName;
StartDate:= FormatDateTime('YYYYMMDD',DTPStart.Date);
Temp:=StrToInt(StartDate);
EndDate:= FormatDateTime('YYYYMMDD',DTPEnd.Date);
end;
end;
procedure TFrmDataFeed.BTNGenerateClick(Sender: TObject);
var
FileName,StartDate,EndDate:string;
Temp:Integer;
begin
if SDDataFeed.Execute then
begin
FileName:=SDDataFeed.FileName;
StartDate:= FormatDateTime('YYYYMMDD',DTPStart.Date);
Temp:=StrToInt(StartDate);
EndDate:= FormatDateTime('YYYYMMDD',DTPEnd.Date);
end;
end;