BInd to events from win service from desktop application

B

bz

Hi,

I need to create a win service that lookup a file ina folder, ands
when received, read it then fir an event.

Then I need a desktop app that, when runs, bind to the event from the
win service, and when the event fires, read the eventarg data and do
some processing with.

Can anyone point me to the right direction to do this?

I will use filesystemwatcher to detect when file changes, but don't
know from there

I know how to do this with COM (the service is a com obj defining an
interface and the desktop app implements that interface and bind to
the running service), but not sure how to do it in NET

Any advice or suggestion is appreciated.

Thank you
 
P

parez

Hi,

I need to create a win service that lookup a file ina folder, ands
when received, read it then fir an event.

Then I need a desktop app that, when runs, bind to the event from the
win service, and when the event fires, read the eventarg data and do
some processing with.

Can anyone point me to the right direction to do this?

I will use filesystemwatcher to detect when file changes, but don't
know from there

I know how to do this with COM (the service is a com obj defining an
interface and the desktop app implements that interface and bind to
the running service), but not sure how to do it in NET

Any advice or suggestion is appreciated.

Thank you

One easy approach is to start off a new process(desktop app) with
appropriate arguments everytime the file changes.
 
B

bz

Hi,

This doesn't works, because I don't want to desktop process to open
everytime.
The service must do what it is designed to do, and the desktop is just
a monitor, users can choose to start when they want to see the status
of service processing.

It might not be started for days, for example

Any other thought?
 
P

parez

Hi,

This doesn't works, because I don't want to desktop process to open
everytime.
The service must do what it is designed to do, and the desktop is just
a monitor, users can choose to start when they want to see the status
of service processing.

It might not be started for days, for example

Any other thought?

then you will have to use some better form of IPC .. named pipes,
remoting or MSMQ


http://www.google.com/search?hl=en&...e+interprocess+communication+.net&btnG=Search
 

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

Top