![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Sep 2005
Posts: 21
Rep Power: 0
![]() |
Inter-program Communication
I need to communicate between two seperate programs. One will read in data from the user, and the second program will take that data and output it. Easy enough, only I'm trying to figure out the most effective ways to do this. I can either:
1) Write the data read in from the 1st program to a file, then read it in from the 2nd program. The problem with this is I'm not sure how the 2nd program will know when there is txt written to the file. 2) Use shared memory. I've never done this before, and not exactly sure where to get information on how it would be done. 3) Use a socket, although I need to do things locally without using networks or IP's addresses. Basically I'm just looking to be pointed in the right direction for the most effective way to do such a thing. This is the first time I've ever done inter-program communication. Suggestions please! |
|
|
|
|
|
#2 |
|
Professional Programmer
|
option 1 is the easiest way, option 2 is the most efficient way, there's nothing wrong with option 3 although when it's on a local machine it basically becomes option 1. Search google for some examples.
-Dizz |
|
|
|
|
|
#3 |
|
Expert Programmer
Join Date: Aug 2005
Location: Rotterdam, the Netherlands
Posts: 942
Rep Power: 4
![]() |
What about pipes? Iself have no experience with them, google.com
.Please do not double post ![]() |
|
|
|
|
|
#4 |
|
Newbie
Join Date: Sep 2005
Posts: 21
Rep Power: 0
![]() |
In doing option one, how would my 2nd program know when there is data to read in? Thanks for the help!
|
|
|
|
|
|
#5 |
|
Expert Programmer
Join Date: Aug 2005
Location: Rotterdam, the Netherlands
Posts: 942
Rep Power: 4
![]() |
using a semaphore? once again, use google, i only know the theories
![]() |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|