全部博文(788)
分类:
2009-06-10 14:03:07
嗨,大家好!
procedure TForm1.Button3Click(Sender: TObject);
begin
With ADOQuery1 do
begin
Close;
SQL.Clear;
SQL.Add('Select * from a ');
Open;
DBEdit1.DataSource := DataSource2;
DBEdit1.DataField := '题号';
DBEdit2.DataSource := DataSource2;
DBEdit2.DataField := '题目';
end;
end;
procedure TForm1.Button4Click(Sender: TObject);
begin
With ADOQuery1 do
begin
Close;
SQL.Clear;
SQL.Add('Select * from S1 ');
Open;
DBEdit1.DataSource := DataSource1;
DBEdit1.DataField := '题号';
DBEdit2.DataSource := DataSource1;
DBEdit2.DataField := '正确答案';
end;
end;
怎么我在按了Button3后在按Button4就出错呢?