Let's say I have a table called adverts with the following fields:advert_id, name,date_created description,duration,status,user_id, cat_id.

Let's say a user puts a duration of 1 week in the duration field and its status is set to active. After a week has passed, the status is set to inactive in the table.

Can anyone tell me if it's possible to do this with asp.net 4.0 code using visual basic in visual studio 2010 with web forms?

3 Years
Discussion Span
Last Post by minhaajmuntasir.edoo

A few ways that come to mind. You can have a remote cron job call an asp.net page on a routine schedule. The only propose of this page is to run your code.

Here is another ..If the DB is being hosted on an edition such as SQL enterprise, you can have the SQL agent run a job on schedule. This job can execute a sql stored procedure to do what you need it to do to your records.

Also, in your global.asax page, you can leverage some of the various events that trigger (such as application start) to execute the code you need to.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.