Command Prompt
-
Hello Guys, I have a controller device (RTOS). I connect to it using "telnet". c:\>telnet ipaddress When i connect to device through telnet, it will show the menu for configuration of device. For example: Press 1 to view configuration. Press 2 to change configuration. ........... Now I want capture the same and display it on my form. And also I want to provide buttons for "View Configuration" and "Change Configuration". ITS LIKE PROVIDING GUI FOR COMMAND PROMPT. How can i do it in VC++? Please Help Me.
-
Hello Guys, I have a controller device (RTOS). I connect to it using "telnet". c:\>telnet ipaddress When i connect to device through telnet, it will show the menu for configuration of device. For example: Press 1 to view configuration. Press 2 to change configuration. ........... Now I want capture the same and display it on my form. And also I want to provide buttons for "View Configuration" and "Change Configuration". ITS LIKE PROVIDING GUI FOR COMMAND PROMPT. How can i do it in VC++? Please Help Me.
It is better to use Windows Pipeline ( for stdioIn and stdioOut ) with the tellnet application. You can read the output ( or write to the input ) of console application to ( or from ) a win32 application through pipelining the stdio file of the console application.
-
It is better to use Windows Pipeline ( for stdioIn and stdioOut ) with the tellnet application. You can read the output ( or write to the input ) of console application to ( or from ) a win32 application through pipelining the stdio file of the console application.
-
Hello Guys, I have a controller device (RTOS). I connect to it using "telnet". c:\>telnet ipaddress When i connect to device through telnet, it will show the menu for configuration of device. For example: Press 1 to view configuration. Press 2 to change configuration. ........... Now I want capture the same and display it on my form. And also I want to provide buttons for "View Configuration" and "Change Configuration". ITS LIKE PROVIDING GUI FOR COMMAND PROMPT. How can i do it in VC++? Please Help Me.
You can use _popen(), _wpopen() They handles the pipe redirection for you. See http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclib/html/_crt__popen.2c_._wpopen.asp[^]
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson
-
Thank you so much for the solution. Will you please give some more information related to Pipeline? (Like, Which Class in Win32? What is stdio file?)
As per my knowledge there are no class in MFC for handling pipelineing you have to use windows API like CreatePipe. CreateProcess etc. For extra reference over them please look at allapi.net and search in http://msdn.microsoft.com/library/default.asp