Run Program()을 사용하여 .bat 파일 실행JSL에서 .bat 파일을 실행하려고 하는데 예상대로 작동하지 않습니다.
내가 무엇을 놓치고 있습니까?
https://www.jmp.com/support/help/en/15.1/#page/jmp/run-external-programs.shtml
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>"자동화 및 스크립팅소비자 및 시장 조사데이터 혼합 및 정리실험 설계품질 및 프로세스 엔지니어링결과 공유 및 소통Re: Run Program()을 사용하여 .bat 파일 실행따옴표가 왜 그렇게 어려운지 설명한 사이트를 찾았습니다.
https://community.jmp.com/t5/Discussions/Unable-to-parse-speechmarks-quot-quot-into-powershell-using/mp/245968/highlight/true#M48328
Re: Run Program()을 사용하여 .bat 파일 실행cmd /c를 사용하여 MS-DOS 또는 cmd.exe에서 명령을 실행할 수 있습니다. 실행하려는 명령 문자열도 추가합니다. 예를 들어 ping poftut.com을 실행하려는 경우 다음 명령을 실행합니다. 이 명령은 명령을 실행할 프로세스를 생성한 다음 명령 실행이 완료된 후 종료합니다. 또한 명령을 둘러싸기 위해 ” 큰따옴표를 사용하는 것이 매우 유용합니다.
--> cmd /c "ping poftut.com"Re: Run Program()을 사용하여 .bat 파일 실행매개변수 1개가 누락되었습니다.
rp = RunProgram( Executable( "cmd.exe" ),
Options( {"/C", "C:\temp\myfile.bat"} ),
ReadFunction("text") // returns all text
);