Automatically update database Table at specific time using C# and VB.Net in ASP.Net

Last Reply 29 days ago By dharmendr

Posted 29 days ago

In my code, while inserting i am entering status='NEW'. Then i want to update this status='PENDING' after 1 day(24 hours) automatically. Can anybody suggest proper query and where this query to be place in the form.

Posted 29 days ago

Hi sambath,

You need to create Windows Service. The Windows Service will run on every hour (Interval) and will automatically trigger a method to fetch records from database and check the status column if the value is new then update it to pending.

Refer below articles.

Simple Windows Service that runs periodically and once a day at specific time using C# and VB.Net

Automatically send emails daily at specific time using Windows Service in C# and VB.Net