Programmer1
Programmer1

Reputation: 23

Accessing the values returned by an executable C++

I am running an executable file (written in C#) from a C++ program using the system command and passing a string to it. The executable file returns some string. Is it possible to access the string returned by the executable file from the C++ program? Is there an easy way to do it using the systems command? I am using visual studio.

Upvotes: 0

Views: 1836

Answers (1)

Sample Player
Sample Player

Reputation: 36

If you mean the string is written to the command line of the c# program and you want to capture it then you could use named pipes to intercept the output generated from the c# program.

see https://msdn.microsoft.com/en-us/library/ms682499.aspx

from your c++ program

Or, please clarify what you mean by "running an executable file" and "using the system command" - are you writing code or running at a command prompt ?

Upvotes: 1

Related Questions