473,386 Members | 1,720 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,386 software developers and data experts.

Interprocess Communication

DC
Hi,

I am using a windows service. Now I need to access some data inside
this service with a windows forms application. As an alternative I
could use a web project to get what I need from the windows service.

That windows forms app or the webapp will sit on the same machine. Am I
right in thinking that I must use marshaling and remoting in order to
make the applications communicate or is there an easier approch?

Thanks for any hint in advance,
Regards
DC

Jan 12 '07 #1
9 2423
Hi DC,
There are a lot of different IPC mechanisms, so I wouldn't say that you
*must* use remoting in order to make the applications communicate. For
example, you could use sockets, named pipes, etc... However, I think
that remoting is probably the easiest approach.

Since you are asking for an easier approach, does that mean you're
having some trouble using remoting?

John

DC wrote:
Hi,

I am using a windows service. Now I need to access some data inside
this service with a windows forms application. As an alternative I
could use a web project to get what I need from the windows service.

That windows forms app or the webapp will sit on the same machine. Am I
right in thinking that I must use marshaling and remoting in order to
make the applications communicate or is there an easier approch?

Thanks for any hint in advance,
Regards
DC
Jan 12 '07 #2
Hello DC,

Just to add to Jonh's post see there several samples of different ways of IPC
http://www.codeproject.com/info/sear...ed=12+Jan+2007

---
WBR,
Michael Nemtsev [C# MVP] :: blog: http://spaces.live.com/laflour

"The greatest danger for most of us is not that our aim is too high and we
miss it, but that it is too low and we reach it" (c) Michelangelo

DHi,
D>
DI am using a windows service. Now I need to access some data inside
Dthis service with a windows forms application. As an alternative I
Dcould use a web project to get what I need from the windows service.
D>
DThat windows forms app or the webapp will sit on the same machine. Am
DI right in thinking that I must use marshaling and remoting in order
Dto make the applications communicate or is there an easier approch?
D>
DThanks for any hint in advance,
DRegards
DDC
Jan 12 '07 #3
*Sigh*

yea, all we have to do is wait for frameworks 3.0
:(

How much of that stuff is just a nice looking wrapper around c++ classes.
Dont get me wrong, I realy like the frameworks.

I do find the wrappers frustrating at times because they dont always
have all of the bells and whistles that the com classes that they rap have.

Eg Named pipes,
Gdi's BitBlt,
.....
"Joerg Jooss" wrote:
Thus wrote TheMadHatter,
"Named Pipes" are always fun :) (probably the fastest too.) It
requires a Pinvoke. Look up "CreateFile".

WCF is probably a better choice here than P/Invoke. The next BCL version
will include named pipe support as well.

Cheers,
--
Joerg Jooss
ne********@joergjooss.de
Jan 13 '07 #4
Thus wrote TheMadHatter,
How much of that stuff is just a nice looking wrapper around c++
classes. Dont get me wrong, I realy like the frameworks.

I do find the wrappers frustrating at times because they dont always
have all of the bells and whistles that the com classes that they rap
have.
Which COM classes does WCF wrap? Or WPF? Or WF?

--
Joerg Jooss
ne********@joergjooss.de
Jan 13 '07 #5
"TheMadHatter" <Th**********@discussions.microsoft.comwrote in message
news:B8**********************************@microsof t.com...
*Sigh*

yea, all we have to do is wait for frameworks 3.0
:(
No you don't, it's been realeased two month ago.
How much of that stuff is just a nice looking wrapper around c++ classes.
Dont get me wrong, I realy like the frameworks.
So what did you expect? They rewrite the whole Win32 API in managed code? The Framework is
nothing more than an API you know.
I do find the wrappers frustrating at times because they dont always
have all of the bells and whistles that the com classes that they rap have.
What are you talking about? nothing in the Framework (V2 and V3) IPC space is actually a
wrapper around COM implementations, all what's done are calls into Win32 API's (sockets,
namedpipes, shared memory etc..).
Named pipes aren't COM wrappers, they are kernel objects.
Willy.

Jan 13 '07 #6
Joerg Jooss wrote:
>How much of that stuff is just a nice looking wrapper around c++
classes. Dont get me wrong, I realy like the frameworks.

I do find the wrappers frustrating at times because they dont always
have all of the bells and whistles that the com classes that they rap
have.

Which COM classes does WCF wrap? Or WPF? Or WF?
One of the supported "service types" (in lack of a better word) for
WCF is COM+, so WCF has something to do with COM.

Arne
Jan 13 '07 #7
Thus wrote Arne_Vajhøj,
Joerg Jooss wrote:
>>How much of that stuff is just a nice looking wrapper around c++
classes. Dont get me wrong, I realy like the frameworks.

I do find the wrappers frustrating at times because they dont always
have all of the bells and whistles that the com classes that they
rap have.
Which COM classes does WCF wrap? Or WPF? Or WF?
One of the supported "service types" (in lack of a better word) for
WCF is COM+, so WCF has something to do with COM.
Could we please stop stabbing in the dark?

WCF can be integrated with existing COM+ services. That doesn't mean WCF
is a thin wrapper around a COM library.
Neither is WCF a ASP.NET wrapper, nor a WSE3 wrapper, nor a COM wrapper,
yet it integrates with all of those quite nicely.

Cheers,
--
Joerg Jooss
ne********@joergjooss.de
Jan 13 '07 #8
DC
Thanks John!

The reason I was asking ist that I have actually never ever implemented
any type of low-level IPC in C#. I will give remoting a try since
performance is really not a big issue for my app.

Regards,
DC

John Duval wrote:
Hi DC,
There are a lot of different IPC mechanisms, so I wouldn't say that you
*must* use remoting in order to make the applications communicate. For
example, you could use sockets, named pipes, etc... However, I think
that remoting is probably the easiest approach.

Since you are asking for an easier approach, does that mean you're
having some trouble using remoting?

John

DC wrote:
Hi,

I am using a windows service. Now I need to access some data inside
this service with a windows forms application. As an alternative I
could use a web project to get what I need from the windows service.

That windows forms app or the webapp will sit on the same machine. Am I
right in thinking that I must use marshaling and remoting in order to
make the applications communicate or is there an easier approch?

Thanks for any hint in advance,
Regards
DC
Jan 15 '07 #9
DC
Thanks Michael!

Very good examples, I had not checked Code Project on IPC yet. I will
probably try a named pipe solution if I somehow don't get along with
remoting.

Regards,
DC

Michael Nemtsev wrote:
Hello DC,

Just to add to Jonh's post see there several samples of different ways of IPC
http://www.codeproject.com/info/sear...ed=12+Jan+2007

---
WBR,
Michael Nemtsev [C# MVP] :: blog: http://spaces.live.com/laflour

"The greatest danger for most of us is not that our aim is too high and we
miss it, but that it is too low and we reach it" (c) Michelangelo

DHi,
D>
DI am using a windows service. Now I need to access some data inside
Dthis service with a windows forms application. As an alternative I
Dcould use a web project to get what I need from the windows service.
D>
DThat windows forms app or the webapp will sit on the same machine. Am
DI right in thinking that I must use marshaling and remoting in order
Dto make the applications communicate or is there an easier approch?
D>
DThanks for any hint in advance,
DRegards
DDC
Jan 15 '07 #10

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

Similar topics

2
by: Jeroen | last post by:
Question, We are in the process of creating a windows service in C#. Another GUI application, also written in C# has to communicate from another machine to this service. What is the best...
7
by: Daniel | last post by:
I search for a good way to communicate between processes. I have a main application(might be more instances) and an tool that should exchange information such as which user is logged in into the...
4
by: Charles Packer | last post by:
I need to do the following simple interprocess communication (IPC) among these processes that are all on the same box: -- A daemon waits for "I'm here" announcements from multiple clients -- One...
5
by: guy | last post by:
In the past I've used sockets in C++ to allow apps to communicate with each other over a local network. Is there anything better/more advanced in .NET or should I continue to use sockets and the...
3
by: James Aguilar | last post by:
Oh wise readers of comp.lang.python, Lend a newbie your ears. I have read several old articles from this group about memory mapping and interprocess communication and have Googled the sh** out...
7
by: Michael Butscher | last post by:
Hi, this is not really Python-specific but I need it for Python. I'm wanting a method for interprocess communication which is OS- independent (sockets would be the normal way to go), but which...
4
by: batista | last post by:
Hello all, I need suggestions and possibly solutions to the problem stated below: I have an application written purely in .NET ( Windows Form Application) and another application that is...
0
by: Murali | last post by:
Hi Python Gurus, I am writing a GUI app (on linux) using pygtk which would launch some external applications and display their stdout and stderr inside the output window of my application...
2
by: Murali | last post by:
Hi Python Gurus, I am writing a GUI app (on linux) using pygtk which would launch some external applications and display their stdout and stderr inside the output window of my application...
3
by: madankarmukta | last post by:
Hi all, I am very new to Implementation of the Interprocess communication.I am trying to implement the concept in c++.I created the pipe using Createnamedpipe() function ,connecting to that pipe...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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...

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.