Click here to Skip to main content
15,909,440 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: how to interact with C from VC++ Pin
Bob Flynn9-Dec-05 6:28
Bob Flynn9-Dec-05 6:28 
AnswerRe: how to interact with C from VC++ Pin
kakan9-Dec-05 2:15
professionalkakan9-Dec-05 2:15 
GeneralRe: how to interact with C from VC++ Pin
sheshidar16-Dec-05 1:07
sheshidar16-Dec-05 1:07 
GeneralRe: how to interact with C from VC++ Pin
kakan16-Dec-05 4:07
professionalkakan16-Dec-05 4:07 
GeneralRe: how to interact with C from VC++ Pin
sheshidar21-Dec-05 2:29
sheshidar21-Dec-05 2:29 
GeneralRe: how to interact with C from VC++ Pin
kakan21-Dec-05 3:25
professionalkakan21-Dec-05 3:25 
GeneralRe: how to interact with C from VC++ Pin
sheshidar21-Dec-05 3:53
sheshidar21-Dec-05 3:53 
GeneralRe: how to interact with C from VC++ Pin
kakan21-Dec-05 20:56
professionalkakan21-Dec-05 20:56 
Hello shesidar. It seems as if we live in different time zones...

The keil-program is the key here. I can think of two different scenarios, with two different solutions.

Scenario 1:
You start the Keil-program for every message to it. You give it the input via the command line. The Keil-program returns it's output to sidout and terminates itself.
For example:
<br />
C:\>Keil_program Status<br />
Status=2<br />
C:\><br />


Scenario 2:
You start the Keil-program. It reads it's input from stdin and responds to stdout. Then it awaits your next command.
For example:
<br />
C:\>Keil_program<br />
Status<br />
Status=2<br />
Exit<br />
Exiting...<br />
C:\><br />


Do you see the difference?

For scenario1, you can create a command line and redirect the output to a (temporary) text file. (Then you read the text file from your VC-program, and display it's result).
Example:
<br />
Keil_program Status >C:\tmp\output.txt<br />

Then read the file C:\tmp\output.txt and display it's content.

For scenario 2:
Have a look at the documentation of the _popen-function.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclib/html/_crt__popen.2c_._wpopen.asp[^]

Kakan
GeneralRe: how to interact with C from VC++ Pin
sheshidar23-Dec-05 0:00
sheshidar23-Dec-05 0:00 
GeneralRe: how to interact with C from VC++ Pin
kakan23-Dec-05 1:43
professionalkakan23-Dec-05 1:43 
GeneralRe: how to interact with C from VC++ Pin
sheshidar23-Dec-05 2:20
sheshidar23-Dec-05 2:20 
QuestionDynamic updation of XML file Pin
srimayank11_codeproject9-Dec-05 0:35
srimayank11_codeproject9-Dec-05 0:35 
AnswerRe: Dynamic updation of XML file Pin
ThatsAlok9-Dec-05 1:09
ThatsAlok9-Dec-05 1:09 
QuestionSerial communication Pin
aloktambi8-Dec-05 23:57
aloktambi8-Dec-05 23:57 
AnswerRe: Serial communication Pin
khan++9-Dec-05 0:08
khan++9-Dec-05 0:08 
AnswerRe: Serial communication Pin
vikas amin9-Dec-05 1:55
vikas amin9-Dec-05 1:55 
QuestionAppearance of disabled/grayed Close [X] button in XP Pin
Mia S8-Dec-05 22:51
Mia S8-Dec-05 22:51 
QuestionichObject Oriented Language Pin
Girish6018-Dec-05 22:29
Girish6018-Dec-05 22:29 
AnswerRe: ichObject Oriented Language Pin
khan++8-Dec-05 22:58
khan++8-Dec-05 22:58 
GeneralRe: ichObject Oriented Language Pin
toxcct8-Dec-05 23:58
toxcct8-Dec-05 23:58 
GeneralRe: ichObject Oriented Language Pin
khan++9-Dec-05 0:17
khan++9-Dec-05 0:17 
GeneralRe: ichObject Oriented Language Pin
toxcct9-Dec-05 0:23
toxcct9-Dec-05 0:23 
AnswerRe: ichObject Oriented Language Pin
toxcct9-Dec-05 0:04
toxcct9-Dec-05 0:04 
AnswerRe: ichObject Oriented Language Pin
ThatsAlok9-Dec-05 1:08
ThatsAlok9-Dec-05 1:08 
GeneralRe: ichObject Oriented Language Pin
Nemanja Trifunovic9-Dec-05 7:30
Nemanja Trifunovic9-Dec-05 7:30 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.