GIDForums  

Go Back   GIDForums > Computer Programming Forums > CPP / C++ Forum
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread Rate Thread
  #1  
Old 01-Mar-2008, 18:10
05gtp 05gtp is offline
Awaiting Email Confirmation
 
Join Date: Aug 2005
Location: Clinton Township (Detroit Area), MI
Posts: 13
05gtp will become famous soon enough

Help communicating between console processes/threads???


I'm not exactly sure how to state the problem. This is all new ground for me.
I'll done googles but a lot of what I found confused me a little more then I expected.

First, in lame man terms, can some one explain the difference between processes and threads?

Second, is it possible to share variables (memory addresses) between console windows?

Third, is it possible to have one console window write to another console window?

Here is the real issue I'm trying to solve. We have Team Center AE (process name imanserver.exe) sessions running on a client workstation. This is a UGS database software application. It is launched through a command window from a batch (.bat) file that sets many environment variables. The user may have multiple sessions running on the client at one time, and each session can be connected to the same database or different databases. Each session has a process, imanserver.exe, running. I have an external C++ application that will auto login to a specific database and do a few things. The issue is, how can I query a process and get the environment variable settings? Only from the env variables can I find which database TcAE is currently connected to. I have it where if more then one imanserver.exe process is found, I inform the user and the application terminates. Only one session of TcAE can be running at a time, one imanserver.exe process. The next part, I need the env variables from the process so I can start a new command window and set the same env variables and launch my application to login the current connected database. Another option may be to launch a child process from the first imanserver.exe process? Is this possible and if so, would the child process inherit the parent environment variables? I know how to get the PID and the process HANDLE. This is only required to run on Windows. This must be done in a form of C++ (VC++, MFC), not C# or VB.

Also, any links would help. I don't mind mining for information.

Any help would be greatly appreciated.

Thanks.
 
 

Recent GIDBlogNARMY by crystalattice

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
win32 CreateProcess(), STARTUPINFO not working well for 98 console Howard_L C Programming Language 0 09-Aug-2007 23:33
Change 98 console character size in program? Howard_L C Programming Language 1 25-Apr-2007 14:25
how to keep the console window from opening tajjyarden CPP / C++ Forum 1 06-Feb-2007 13:40
need help with a console menu system BullBuchanan CPP / C++ Forum 6 20-Aug-2006 14:46
Bloodshed Dev C++ Project Options JdS CPP / C++ Forum 6 11-Nov-2005 17:23

Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The

All times are GMT -6. The time now is 04:35.


vBulletin, Copyright © 2000 - 2008, Jelsoft Enterprises Ltd.