Click here to Skip to main content
15,888,461 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
HI


I would like to know how would it be possible for me to automate a button action in vb.net.

Currently i have a user who clicks a button and the code is executed.

I now want to change it so that this code is run everyday at a certain time(midnight).
Posted
Comments
bbirajdar 26-Mar-13 5:20am    
Write a windows service

yes this can be done by calling a function in a timer object.
set up a few variables to get the system time and compare it with the time u want.

when the compare returns true then call the button event handler.
 
Share this answer
 
Hi,

You have the following possibilities:

1. Make a windows service;
     Walkthrough: Creating a Windows Service Application in the Component Designer
2. Make a schedule task (windows os);
     Schedule a task
 
Share this answer
 
You needs to create Sql Server Agent jobs for such requirements.
Please refer below links & serch for more info.

http://www.aspsnippets.com/Articles/Automated-Email-Notifications-using-SQL-Server-Job-Schedular.aspx[^]

http://msdn.microsoft.com/en-us/library/ms190268.aspx[^]
 
Share this answer
 
Comments
[no name] 27-Mar-13 7:12am    
Where did you get the idea that he is using a database at all?
Jonathan [Darka] 27-Mar-13 9:33am    
He just needs to use a timer or schedule, this question is nothing to do with SQL or databases.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900