Accessing a windows Service from a web form

R

Roger Twomey

Can a .Net web form interact with a .Net web service? More importantly...
How?

I have written a web-service which runs on a timer to check for data in a
database that needs to be 'operated' on. The data is entered into the
database from web, telephone and Windows applications. Rather than write 3
versions of the same code I wrote it once in a windows service which happens
to run on the web server.

What I would like to do; from the web when a user completes the steps
necessary to create the data which needs to be used, access the function in
the Windows Service to start the operations on the data, rather than wait
for the timer.

Does anyone have a sample of code (preferably VB but I will try to figure
out C# if I need to) showing how a web-form might call/use a function in a
Windows Service?

Thanks.
 
S

Sandy Murdock

I am not familiar with a file watcher. I looked it up in the visual
studio help files, it sounds like that would work.

Any idea what kind of a load that puts on the CPU? It must check on some
kind of timer?


Sandy Murdock MCP
 
E

Eliyahu Goldin

Get you web application to make files with the data to be passed and equip
the windows service with a file watcher that will detect file creating and
initiate data consuming.

Eliyahu
 
E

Eliyahu Goldin

Sandy,

It doesn't put any load on the CPU at all. I have a multi-thread windows
service with tens of watchers watching in the same time. I think it works
with windows events. That's why it doesn't work with network directories.

Eliyahu
 
B

Bruce Barker

the .net approach would be to have your service support remoting. then the
web service could call the windows service to trigger the work.

-- bruce (sqlwork.com)
 

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

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,576
Members
45,054
Latest member
LucyCarper

Latest Threads

Top