andyhill Posted July 16, 2020 Share Posted July 16, 2020 I have a procedure that within the code while loop (while not Query.Eof do begin etc.) I want to Execute 2 Ajax Events (repeated over and over on each record):- ////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////// WaitLoopFlag:= True; UniSession.AddJS('ajaxRequest(fMain.HtmlMemo, ''_sample_'', []);'); // On Completion WaitLoopFlag Is Set To False while WaitLoopFlag = True do begin Sleep(5000); end; ////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////// WaitLoopFlag:= True; UniSession.AddJS('ajaxRequest(fMain.HtmlMemo, ''_process_'', []);'); // On Completion WaitLoopFlag Is Set To False while WaitLoopFlag = True do begin Sleep(5000); end; My problem is the Ajax Events are never fired when called within a loop, can anyone please advise how to resolve - thanks in advance 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.