rp = RunProgram( Executable( "cmd.exe" ),
Options( {"C:\temp\myfile.bat"} ),
ReadFunction("text") // returns all text
);
//"Microsoft Windows [Version xxx]
//(c) 2018 Microsoft Corporation. All rights reserved.
//
// C:\Program Files\SAS\JMPPRO\15>"
Created:
Sep 20, 2020 10:55 PM
| Last Modified: Sep 20, 2020 7:55 PM(2136 views)
| Posted in reply to message from ThuongLe 09-20-2020
We can run commands in MS-DOS or in cmd.exe by using cmd /c. We will also add the command string we want to run. For example, if we want to run ping poftut.com we will issue the following command. The command will create a process that will run command and then terminate after the command execution is completed. Also using ” double quotes in order to surround command are very useful.
Created:
Sep 20, 2020 10:55 PM
| Last Modified: Sep 20, 2020 7:55 PM(2137 views)
| Posted in reply to message from ThuongLe 09-20-2020
We can run commands in MS-DOS or in cmd.exe by using cmd /c. We will also add the command string we want to run. For example, if we want to run ping poftut.com we will issue the following command. The command will create a process that will run command and then terminate after the command execution is completed. Also using ” double quotes in order to surround command are very useful.