F
fujingkai
Unregistered / Unconfirmed
GUEST, unregistred user!
//初始单号
for i:=1 to 9999 do
begin
SID:=FormatdateTime('yymmdd', Now)+FormatFloat('0000',i);
ADOQuery2.SQL.Clear;
ADOQuery2.SQL.Add('Select * from Sell_Main Where InvoiceID="'+SID+'"');
ADOQuery2.Open;
if ADOQuery2.RecordCount=0 then
begin
Break;
end;
end;
//读取单号
Label26.Caption:=SID;
ADOQuery1.SQL.Clear;
ADOQuery1.SQL.Add('Select * from Sell_Minor Where InvoiceID="'+Label26.Caption+'"');
ADOQuery1.Open;
end;
我一测试时就出现列(label26.caption)不存在
for i:=1 to 9999 do
begin
SID:=FormatdateTime('yymmdd', Now)+FormatFloat('0000',i);
ADOQuery2.SQL.Clear;
ADOQuery2.SQL.Add('Select * from Sell_Main Where InvoiceID="'+SID+'"');
ADOQuery2.Open;
if ADOQuery2.RecordCount=0 then
begin
Break;
end;
end;
//读取单号
Label26.Caption:=SID;
ADOQuery1.SQL.Clear;
ADOQuery1.SQL.Add('Select * from Sell_Minor Where InvoiceID="'+Label26.Caption+'"');
ADOQuery1.Open;
end;
我一测试时就出现列(label26.caption)不存在