PC Review


Reply
Thread Tools Rate Thread

How to communicaton between two applications

 
 
George Chen
Guest
Posts: n/a
 
      17th May 2005
Hi

I have lots applications are already written by C++. It 's easy to use
PostMessage in one application and catch this message in another
application's WndProc Function.
Since .net have some powerful library. I use C# to develop new
application. But I do not know how to using simlar function in C# to
communication to my exist C++ application.
Any help would be appreciate.

George chen


 
Reply With Quote
 
 
 
 
Eugene Mayevski
Guest
Posts: n/a
 
      17th May 2005
Hello!
You wrote on Tue, 17 May 2005 11:42:24 -0700:

GC> Since .net have some powerful library. I use C# to develop new
GC> application. But I do not know how to using simlar function in C# to
GC> communication to my exist C++ application.

You can try MsgConnect ( http://www.eldos.com/msgconnect/ ) for this.
MsgConnect lets you communicate between applications residing on the same or
different systems easily using TCP, UDP, HTTP, memory-mapped files.

With best regards,
Eugene Mayevski

 
Reply With Quote
 
George Chen
Guest
Posts: n/a
 
      17th May 2005
Thanks Eugene,

Since my application runs on PocketPC, I am afraid MsgConnecct can not
run on PocketPC.
I just want to find a simple method to notify each other. Here is my code
in C++:
App a:
#define WM_SCANBARCODE WM_APP + 100
::PostMessage(HWND_BROADCAST, WM_SCANBARCODE , 0, 0);
App b:
case WM_SCANBARCODE: // WM_SCANBARCODE = WM_APP + 100
break;

Thanks anyway,
George Chen




"Eugene Mayevski" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Hello!
> You wrote on Tue, 17 May 2005 11:42:24 -0700:
>
> GC> Since .net have some powerful library. I use C# to develop new
> GC> application. But I do not know how to using simlar function in C# to
> GC> communication to my exist C++ application.
>
> You can try MsgConnect ( http://www.eldos.com/msgconnect/ ) for this.
> MsgConnect lets you communicate between applications residing on the same
> or
> different systems easily using TCP, UDP, HTTP, memory-mapped files.
>
> With best regards,
> Eugene Mayevski
>



 
Reply With Quote
 
Mattias Sjögren
Guest
Posts: n/a
 
      17th May 2005

> Since .net have some powerful library. I use C# to develop new
>application. But I do not know how to using simlar function in C# to
>communication to my exist C++ application.


PostMessage can still be used.



Mattias

--
Mattias Sjögren [MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.
 
Reply With Quote
 
Amil
Guest
Posts: n/a
 
      17th May 2005
MSMQ?

"George Chen" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Hi
>
> I have lots applications are already written by C++. It 's easy to use
> PostMessage in one application and catch this message in another
> application's WndProc Function.
> Since .net have some powerful library. I use C# to develop new
> application. But I do not know how to using simlar function in C# to
> communication to my exist C++ application.
> Any help would be appreciate.
>
> George chen
>
>



 
Reply With Quote
 
George Chen
Guest
Posts: n/a
 
      17th May 2005
Thanks Mattias

For the sender, PostMessage can still be used in C#.
But, for the receiver, How does it get this notification message in C#?

Thanks
George Chen

"Mattias Sjögren" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
>
>> Since .net have some powerful library. I use C# to develop new
>>application. But I do not know how to using simlar function in C# to
>>communication to my exist C++ application.

>
> PostMessage can still be used.
>
>
>
> Mattias
>
> --
> Mattias Sjögren [MVP] mattias @ mvps.org
> http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
> Please reply only to the newsgroup.



 
Reply With Quote
 
George Chen
Guest
Posts: n/a
 
      17th May 2005
Hi, my friend
In order to using MSMQ, I have to rewrite my c++ appliction. but the
application is deployed to many customer already.
Thanks anyway
George

"Amil" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> MSMQ?
>
> "George Chen" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> Hi
>>
>> I have lots applications are already written by C++. It 's easy to use
>> PostMessage in one application and catch this message in another
>> application's WndProc Function.
>> Since .net have some powerful library. I use C# to develop new
>> application. But I do not know how to using simlar function in C# to
>> communication to my exist C++ application.
>> Any help would be appreciate.
>>
>> George chen
>>
>>

>
>



 
Reply With Quote
 
Mattias Sjögren
Guest
Posts: n/a
 
      17th May 2005

> But, for the receiver, How does it get this notification message in C#?


Override the WndProc method on the recieving form.



Mattias

--
Mattias Sjögren [MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.
 
Reply With Quote
 
George Chen
Guest
Posts: n/a
 
      17th May 2005
Hi Mattias
I found I can override Class Form's WndProc Function from a Windows
Application.
But, Form's WndProc Function is not found from a Smart Device Application.
Only 5 protected function OnActivated, OnClosed, OnClosing, OnDeactivate and
OnLoad can be overrided. You know, compact framework has lack of
functionality.
Thanks again.

George Chen

"Mattias Sjögren" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
>
>> But, for the receiver, How does it get this notification message in C#?

>
> Override the WndProc method on the recieving form.
>
>
>
> Mattias
>
> --
> Mattias Sjögren [MVP] mattias @ mvps.org
> http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
> Please reply only to the newsgroup.



 
Reply With Quote
 
Mattias Sjögren
Guest
Posts: n/a
 
      17th May 2005
>Only 5 protected function OnActivated, OnClosed, OnClosing, OnDeactivate and
>OnLoad can be overrided. You know, compact framework has lack of
>functionality.


If you're targeting CF you can probably get better help in the group
microsoft.public.dotnet.framework.compactframework



Mattias

--
Mattias Sjögren [MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to port windows applications to compact framework applications? miloszl@gmx.de Microsoft Dot NET Compact Framework 4 15th Jun 2005 12:18 PM
How to communicaton between two applications George Chen Microsoft VC .NET 16 1st Jun 2005 09:12 AM
How to communicaton between two applications George Chen Microsoft C# .NET 16 1st Jun 2005 09:12 AM
How to communicaton between two applications George Chen Microsoft Dot NET 1 17th May 2005 11:20 PM
errors with serial communicaton Matteo Cima Microsoft Dot NET Compact Framework 1 13th Nov 2003 03:27 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:56 AM.