Y
yfq101
Unregistered / Unconfirmed
GUEST, unregistred user!
用类似下面的用法,总是出现“parameter 对象被不正确引用 ”的错误。with adouery1 do begin Close; SQL.Clear; SQL.Add ('insert into tablename(id1,id2,id3,)'); SQL.Add ('valuesval1,:val2,:val3)'); Parameters.ParamByName('val1').value:=edit1.Text; Parameters.ParamByName('val2').value:=edit2.Text; Parameters.ParamByName('val3').value:=edit3.Text; ExecSQL; Close; SQL.Add ('select id1,id2,id3 from tablename'); try Open; except showmessage('wrong'); application.Terminate; end; end;