The event BeforeUpdateExecute exists and it allows me to set parameters, which is great.
However I need to do the same thing for insert and delete but those events don't seem to exist???
How can I fill in some parameters with SQLInsert and SQLDelete? Most parameters are taken from the dataset, such as the ID, but there are some parameters that I need to fill in myself (for example the user ID).
BeforeInsertExecute BeforeDeleteExecute ?
Hello,
The BeforeUpdateExecute event occurs before executing insert, delete, update, lock and refresh operations.
Here is an example of using it:
The BeforeUpdateExecute event occurs before executing insert, delete, update, lock and refresh operations.
Here is an example of using it:
Code: Select all
procedure TMainForm.MSQueryBeforeUpdateExecute(Sender: TCustomMSDataSet;
StatementTypes: TStatementTypes; Params: TMSParams);
begin
if stInsert in StatementTypes then
//your code
else
if stDelete in StatementTypes then
//your code
else
if stUpdate in StatementTypes then
//your code
end;