PC SOFT

FOROS PROFESIONALES
WINDEVWEBDEV y WINDEV Mobile

Inicio → WEBDEV 2024 → Implementing a timer which runs server code
Implementing a timer which runs server code
Iniciado por Deon, 16,oct. 2013 08:14 - 2 respuestas
Publicado el 16,octubre 2013 - 08:14
I am using WinDev 18. I have developed pages with a timer control which executes browser code. This works fine, but I need to use a timer to refresh a query (which is server code) The manual explains that a timer cannot be used for running server code, and refers to a method that will handle server code from a timer. The question is - Where is this method?. How do I do it?
Anyone with a suggestion?
Publicado el 16,octubre 2013 - 13:45
Hi Deon

you have 2 possibilities in both case with a browser timer:
-either you use executeprocess from inside the timer code to run a
button click code (both browser AND server, possibily in ajax mode)
-or you use ajaxexecute/ajaxexecuteAsynchronous in your browser/timer code

First one will give you the possibility to refresh complex structures
(tables/loopers...) easily in the server code
Second will allow running code on the server with minimum traffic, and
is perfect when you don't need to refresh a LOT of controls

Best regards


--
Fabrice Harari
International WinDev, WebDev and WinDev mobile Consulting

More information on http://www.fabriceharari.com


On 10/16/2013 12:14 AM, Deon wrote:
I am using WinDev 18. I have developed pages with a timer control which
executes browser code. This works fine, but I need to use a timer to
refresh a query (which is server code) The manual explains that a timer
cannot be used for running server code, and refers to a method that will
handle server code from a timer. The question is - Where is this
method?. How do I do it?
Anyone with a suggestion?
Publicado el 31,octubre 2013 - 07:11
Thanks Fabrice,

I will definitely try out both these options.
Thank You for the feedback