erich.wanker Posted March 12, 2021 Share Posted March 12, 2021 i have a 1.90.0.1545 -UniGui app with Hyperserver .. And nothing happens with the UniThreadTimer .. and nothing is stored in Log-File what make i wrong?? procedure TUniServerModule.UniGUIServerModuleCreate(Sender: TObject); begin UniThreadTimer1.Enabled:=true; Logger.AddLog('Servermodule startet am::' + datetostr(now)); MimeTable.AddMimeType('rtf', 'application/rtf', False); end; procedure TUniServerModule.UniThreadTimer1Timer(Sender: TObject); begin UniThreadTimer1.Lock; try Logger.AddLog('lastSync:' + datetostr(now)); // do something WITHOUT using main, mainmodule or something else ThanX for help erich Quote Link to comment Share on other sites More sharing options...
Ron Posted March 12, 2021 Share Posted March 12, 2021 As long as I unlock the timer after having done something, it works in my project running as a DLL under Apache. procedure TUniServerModule.UniThreadTimer1Timer(Sender: TObject); begin UniThreadTimer1.Lock; syslog('test server'); UniThreadTimer1.Unlock; end; Quote Link to comment Share on other sites More sharing options...
eduardosuruagy Posted June 30, 2021 Share Posted June 30, 2021 In this code, what is the UniThreadTimer1.Lock command for? procedure TUniServerModule.UniThreadTimer1Timer(Sender: TObject); begin UniThreadTimer1.Lock; syslog('test server'); UniThreadTimer1.Unlock; end; Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.