473,398 Members | 2,212 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

Bind to events raised from win service in desktop app

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
Jun 27 '08 #1
2 1011

"bz" <bz*****@gmail.comwrote in message
news:04**********************************@y38g2000 hsy.googlegroups.com...
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.

You need to use .Net Remoting to allow the Service and the Desktop app to
talk to each other, which is not that easy. Dotnet Remoting replaces COM.
You can make a .Net application use a COM object too and use COM ports for
communications on a Win O/S computer -- use Google and look it up or
Dogpile.com.

Here is something that may be useful that may allow you to communicate from
one program to another.

http://www.codeproject.com/KB/cs/XDMessaging.aspx

Jun 27 '08 #2
bz
This links is very interesting, I'll check this concept

Thank you

On Apr 29, 2:05*am, "Mr. Arnold" <MR. Arn...@Arnold.comwrote:
"bz" <bzam...@gmail.comwrote in message

news:04**********************************@y38g2000 hsy.googlegroups.com...


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.

You need to use .Net Remoting to allow the Service and the Desktop app to
talk to each other, which is not that easy. Dotnet Remoting replaces COM.
You can make a .Net application use a COM object too and use COM ports for
communications on a Win O/S computer *-- use Google and look it up or
Dogpile.com.

Here is something that may be useful that may allow you to communicate from
one program to another.

http://www.codeproject.com/KB/cs/XDMessaging.aspx- Hide quoted text -

- Show quoted text -
Jun 27 '08 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: esafran | last post by:
Hi, I've have encountered a very strange behaviour under C#. My application is registering for: Microsoft.Win32.SystemEvents.DisplaySettingsChanged &...
6
by: ankurw | last post by:
Hi All, I am experiencing a frustrating issue with hooking into COM events from a Windows service writting in C#. I create a COM object in the service and hook into an event exposed by the...
4
by: Curious Coder | last post by:
I have been tasked with a project that I do not think can be accomplished. Our company has an application that runs as an unmanaged ActiveX control on user desktops. It is designed to work with...
0
by: GenaK | last post by:
Hi all, I need to use a com interface inside a web service. This interface has an event that is raised in response to a function call. I need to stop web service from returning a response back...
1
by: Mary | last post by:
Dear All I have a webservice which has reference to the ATL COM, as we know that ATL COM of VC raises events i get those events in my web service of VB.net. But now the clients will have a web...
0
by: Mary | last post by:
Dear All I have a ATL COM exe, this has some events and functions. i need to give web support to this exe, hence making a wrapper of this by giving this a reference in a webservice. In the .net...
1
by: Apu Nahasapeemapetilon | last post by:
Hello and thank you in advance for your help. Can anyone think of a reason why this code would work properly on one PC, but not another? I've got a System.Windows.Forms.UserControl that...
5
by: Daniel | last post by:
Hey guys When you hook an event (c# 2.0 syntax): myEvent += MyMethodToFire; You need to also unsubscribe it to avoid a resource leak so that the object it is in gets garbage collected like so...
4
by: bz | last post by:
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...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.