Hello,
I use a TUniQuery component and assign a sql select statement to the UniQuery.SQL property. So far so good, but what if the sql statement is wrong, is there an exception thrown (if yes how can I get the error message?) or is there an event to handle? I want to avoid that a default dialog appears...
Thanks in advance!
SQL Error
No exception is raised when you assign SQL text. Exception can be raised when you call Prepare, Execute, or Open.
Code: Select all
try
UniQuery.Open;
except
on E: EUniError do
ShowMessage(E.Message);
end;