S
s1520
Unregistered / Unconfirmed
GUEST, unregistred user!
我在ADOTable 中建了永久字段,在它的OnGetText事件中写
procedure TDataModule1.ADOQ_housebuildingnameGetText(Sender: TField;
var Text: String; DisplayText: Boolean);
begin
if ADOQ_house.Fields[28].AsString='' then text:=''
else
begin
ADOT_jiangz.Locate('buildingname_code',trim(ADOQ_house.Fields[28].AsString),[]);
text:=trim( ADOT_jiangz.Fields[1].AsString);
end;
end; 但是它不执行 if ADOQ_house.Fields[28].AsString='' then text:=''
procedure TDataModule1.ADOQ_housebuildingnameGetText(Sender: TField;
var Text: String; DisplayText: Boolean);
begin
if ADOQ_house.Fields[28].AsString='' then text:=''
else
begin
ADOT_jiangz.Locate('buildingname_code',trim(ADOQ_house.Fields[28].AsString),[]);
text:=trim( ADOT_jiangz.Fields[1].AsString);
end;
end; 但是它不执行 if ADOQ_house.Fields[28].AsString='' then text:=''