Web Server-Side programming

For example, I will need to execute every 5 hours a database backup or a database maintenance OR to move/edit some local files stored on web server or whatever execution on web server but in scheduling. My question is the following : On which component, we can write a Server-Side code to execute and schedule tasks ? How they will start ? Can they start, with the APP.Open Event ? How I can put a timer there for schedule tasks ? Can these tasks to execute asynchronous and on different thread for the rest of web server’s activities ? I am thinking to store on Sqlite, the results of tasks, so if the server restart, to have a point from where to restart these tasks.

Thanks for your time,

It would be better to use the scheduling capabilities of the OS, such as cron.

Why ? Xojo does not supports to have server side programming ? Reading from documentation, I am not sure and this is the reason that I am asking …

You can’t write a better scheduler than the OS did. If your app crashes for some reason, your schedule doesn’t run. That isn’t an issue with the OS. Yes, you can do everything you listed. But why? Instead, write the console apps (or shell scripts) to do what you need and schedule them with the OS.

Just my 2 cents.


I am thinking as a customer with bad computerize knowledge on computer support. All the customers want one system to do everything. They dont want to have linux experts to check the Crons, etc. They want from us, One System, to have the good reporting about the status of the system. This is the reason that I am re-asking, if all of these are possible to programming through Web Xojo. Except from timer object, there is any other way to execute scheduling ?

I am doing a product evaluation for web database solutions tools, on this period. I had a bad experience with some other product (Wakanda) and I dont want to lose more time on development before to be sure that the tool is working for the promising functionality.

Yes it is all possible with Xojo. In fact, I have written a scheduler for other reasons. I just wanted to point out that it isn’t the best practices approach.

There are 2 ways.

  1. Use a Timer
  2. Use a Thread that sleeps until the next scheduled event.

I use a Timer.

I agree with Tim. Your work to make things more user friendly would be better directed at putting a pretty face around the standard OS facilities than implementing your own in-app. Just my 2 cents.

Why not use Xojo to maintain the crontab file?

Thanks for your responses. I will use crontab to call a xojo shell application.