Calling webservice at intervals

D

Dotnet guy

I have a webservice that gets rid of the duplicate records
in the database. I want it to run every 24 hrs. How do I
set it or call it my application and get it run every 24
hrs?

Any help is appreciated.

Thanks.
 
D

Dino Chiesa [Microsoft]

A webservice, in my book, is a bit of logic that runs in response to
incoming web method requests (or web service requests, if you like).
Just as a dynaminc webpage does not "run" *periodically*, but instead only
"runs" when a browser requests it, a webservice only "runs" when a request
for it is received at the server.

If you want a bit of logic to run periodically, there is a schtasks.exe
utility to set this up in windows[1, 2]. There is also a GUI for this
facility [3], called Task Scheduler. To get there on WinXP,
Start....Control Panel....Scheduled Tasks....Add New Task (or something
close to that). The function is something like the Unix cron utility, if
you are familiar with that. You could, for example, set up a tasks that
invokes a webservice CLIENT to run, once every 24 hours, at precisely 542am.
That client could then send out a "clean up your data" request to a
(possibly) remote webservice. Or, if you have access to the server itself,
you could have the "clean up your data" logic to run as a task, and no
webservices would be involved at all. The scheduled task would do all the
heavy lifting itself.

-D

[1]
http://www.microsoft.com/technet/prodtechnol/winxppro/proddocs/schtasks.asp
[2]
http://www.microsoft.com/technet/pr...3/proddocs/entserver/schtasks_commandline.asp
[3]
http://www.microsoft.com/technet/pr...r2003/proddocs/standard/Tasksched_topnode.asp
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,995
Messages
2,570,226
Members
46,815
Latest member
treekmostly22

Latest Threads

Top