I have spent 3 and a half years exclusively in the UniGUI Mobile world where most things work after effort and today tried to build the most simplest Desktop App with a Login Form and Thread Timer.
I cannot get the Thread Timer Event to call the fLogin Form Ajax Event ? Please advise - Thanks
procedure TfLogin.ttTimeOutTimer(Sender: TObject);
begin
ttTimeOut.Enabled:= False;
WaitFlag:= False;
// Below Fails (along with about 10 other variants of calling)
UniSession.AddJS('ajaxRequest(fLogin.window, "_TimerReset_", []');
UniSession.AddJS('ajaxRequest(' + fLogin.Form + ', "_TimerReset_", []');
UniSession.AddJS('ajaxRequest(' + fLogin.WebForm.JSName + ', "_TimerReset_", []');
UniSession.AddJS('ajaxRequest(' + Chr(39)+fLogin.GetWebForm.Name+Chr(39) + ', "_TimerReset_", []');
end;
procedure TfLogin.UniLoginFormAjaxEvent(Sender: TComponent; EventName: string; Params: TUniStrings);
begin
if EventName = '_TimerReset_' then begin
Caption:= 'Login';
UniSession.Synchronize();
end;
end;