RobertP
14th January 2023, 16:15
I have a DLL updating table Z with commit. DAL hook after.commit.transaction() is never called.
How can it be invoked?
In std LN when is this hook called?
Thanks.
vahdani
19th January 2023, 00:19
Hi,
according to the help file the DAL function after.commit.transaction() is "called just after the after.update.db.commit event section in a UI script."
and "It is not called by Data Access Methods or commit.transaction()"
So it is obvious that it will not be called from your DLL script after "commit.transaction()"!!
Your solution could be to call this DAL-function yourself
...
ret = commmit.transaction()
if ret = 0 then
after.commit.transaction()
endif
This will not work if you have declared more than one DAL with after.commit.transaction function!!
OmeLuuk
19th January 2023, 11:42
This will not work if you have declared more than one DAL with after.commit.transaction function!!in which case you could probably call it by the full name <object>.<function>. If that does not work you need to use keyword extern in the functionname, but as you call it manually the function name can be anything.
RobertP
19th January 2023, 11:57
Thanks Vahdani and Omeluuk. I will test this later on the week. For now I've established workaround. Will keep you posted.