Help on how to create intra-application communication

  • Thread starter Thread starter Support
  • Start date Start date
S

Support

Hello:
I have done some research on the following but still not clear as what
mechanism is preferable
PROBLEM:
In a VB.NET environment, I will have two applications.

Application (A) will do some windows/database stuff which results in a value
being "returned"
Application (B) contains a text field and a button which opens application
(A)

DESIRED PROCESS:
Application (B) calls Application (A) and (A) goes modal
Application (A) does some work and when I Close (A) it "returns" a
value: Ret_A
Application (B) reads the value Ret_A

RESEARCH:
I looked at MSMQ which seems "heavy" to run on client XP's just for
this.
I looked at stdio which (A) could open and (B) could read but I do not
want a console window to open but could work if the console window was
invisible ...

I looked at remoting but both application will be running on the same
computer, so remoting seems overkill

I looked at the SendMessage() API but most examples I see are for vb 6.0

I looked at (A) writing to registry and (B) reading from registry on a
separate thread using a timer process (every second) but that does not seem
to have any integrity - it is just a third party mail drop and could get
screwed-up.

I would appreciate your opinion
Thanks
Terry
 
Thanks - how would B know when the file was written - seems like the same
issue: how does B know when A is finished...
I would like A to tell B the file was written and to take a look at it
without using something like the heavy Filewatcher class..
I will look at the link
Thanks

Anand[MVP} said:
How about A writing to a file that B can read?? There is managed
implementation of Shared memory too
(http://staff.develop.com/richardb/weblog/PermaLink.aspx/32c3abfb-bac9-4e19-
bbc5-39ca338d906d), which may also be an option.
 
You could even look at a named pipe(or a socket based one) based communication channel, if you find it a problem with Shared Memory.

--
Regards,
Anand M
VB.NET MVP

http://www.dotnetindia.com


Support said:
Thanks - how would B know when the file was written - seems like the same
issue: how does B know when A is finished...
I would like A to tell B the file was written and to take a look at it
without using something like the heavy Filewatcher class..
I will look at the link
Thanks

Anand[MVP} said:
How about A writing to a file that B can read?? There is managed
implementation of Shared memory too
(http://staff.develop.com/richardb/weblog/PermaLink.aspx/32c3abfb-bac9-4e19-
bbc5-39ca338d906d), which may also be an option.
 
Back
Top