Unfortunately this thread is already closed
I’m running into the same issue. This is really inconvenient, since I’ve been using this kind of handover extensively in all my projects. Now I have to rework every single project, which is going to take a lot of effort. And I can’t yet tell if there will be side effects.
Is there a way to solve this more easily?
Error:
[Fehler] Pfand.Pfandware.Edit.pas(254): Incompatible type for arg no. 1: Got "TJSPromise", expected "TExecOnReadyCall"
Here is my example usage:
TMyForm = class ...
[async] procedure ShowData;
procedure TMyForm.xxxxxxxx;
begin
...
if FormField[ cLoaded] then
ExecOnReady( ShowData) // <-- Now Error
else if FPageState = esEdit then
ExecOnReady( LoadData)
else
InitData;
...
end;
in another unit, available globally
procedure TWebDataForm.ExecOnReady( AExecProc: TExecOnReadyCall);
begin
if CheckIsReady then
AExecProc
else
FOnReadyExecList.Add( TExecOnReadyEvent.Create( AExecProc));
end;
This isn't an isolated case. I have several such uses.
Is there a way to make my work easier?