Is the string always of the same size and not too big? If yes, you could
implement a DLL with a shared segment. This is by far the fastest option,
because both processes would effectively share the same physical memory.
> Dear Bruno,
> it does not have to work on different computers, both parts always run on
> the same PC. Is there a better option or do you still advice to use
> sockets?
> Thanks a lot,
Marcus Heege - 13 Mar 2006 14:37 GMT
Look here [1] for a desciption of shared segments. You may also want to read
the documentation of #pragma segment and __declspec(allocate)
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/_co
re_how_do_i_share_data_in_my_dll_with_an_application_or_with_other_dlls.3f.asp
> Is the string always of the same size and not too big? If yes, you could
> implement a DLL with a shared segment. This is by far the fastest option,
[quoted text clipped - 5 lines]
>> sockets?
>> Thanks a lot,
Boni - 13 Mar 2006 21:59 GMT
Hi Marcus,
How do I notify another process, that it is time to take data?
> Is the string always of the same size and not too big? If yes, you could
> implement a DLL with a shared segment. This is by far the fastest option,
[quoted text clipped - 5 lines]
>> sockets?
>> Thanks a lot,
Marcus Heege - 13 Mar 2006 22:16 GMT
Look for the documentation of the CreateEvent, SetEvent, WaitForSingleObject
and CloseHandle APIs. An event in as named cross proccess OS object that can
be used for thread serialization. You can see an event like a boolean flag.
The receiver of the data can block its thread (WaitForSingleObject) until
the boolean flag is set to true by the sender thread (SetEvent).
In the MSDN documentation you should find a sample application.
Marcus
> Hi Marcus,
> How do I notify another process, that it is time to take data?
[quoted text clipped - 8 lines]
>>> sockets?
>>> Thanks a lot,
Boni - 13 Mar 2006 22:48 GMT
It does not sound easy :(.
What I need is:
Proc1 requests data (sends address to Proc2)
Proc2 sends data back.
The speed is important.
Is there no easier solution?
> Look for the documentation of the CreateEvent, SetEvent,
> WaitForSingleObject and CloseHandle APIs. An event in as named cross
[quoted text clipped - 20 lines]
>>>> sockets?
>>>> Thanks a lot,
Marcus Heege - 13 Mar 2006 22:59 GMT
> It does not sound easy :(.
> What I need is:
> Proc1 requests data (sends address to Proc2)
> Proc2 sends data back.
> The speed is important.
> Is there no easier solution?
This sounds pretty much like a socket application. Sockets exist in managed
and native APIs. So this should be doable.
AP - 28 May 2006 15:15 GMT
Guys. First of all the programming was never easy. Second: looking for
answers in some goups without having loooked through MSDN is nonsense.
Nobody will fill your head with knowlege you suppose to earn. Moreover. Even
if you think you have picked up some knowlege without earning - you will
fail horobly. Now, READ the MSDN, take examples, create your own application,
compile , run and fail till you fix it.
NOBODY WILL DO IT FOR YOU !!! never.
> Dear Bruno,
> it does not have to work on different computers, both parts always run on
> the same PC. Is there a better option or do you still advice to use sockets?
> Thanks a lot,
Since you mentioned 'on any computer, regardless of firewall settings' i
assumed that you wanted to use different computers.
The advantage of using sockets is that there is no limitation to what you
can send (types of data, size of data, ...) and you can seamlesly move
applications to different computers.
If you are sure that different computers are never necessary, there are
simpler options like pipes for example.
you can find a good overview here:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/ipc/base/interp
rocess_communications.asp

Signature
Kind regards,
Bruno.
bruno_nos_pam_van_dooren@hotmail.com
Remove only "_nos_pam"
Boni - 13 Mar 2006 15:23 GMT
Just before I knew nothing about the topic and now I have a full overview.
Thanks a lot Bruno and Marcus for sharing this.
>> Dear Bruno,
>> it does not have to work on different computers, both parts always run on
[quoted text clipped - 14 lines]
> you can find a good overview here:
> http://msdn.microsoft.com/library/default.asp?url=/library/en-us/ipc/base/interp
rocess_communications.asp