So in cmd I can run
jmp.exe C:\script.jsl
and it will open JMP and run the script. Anyone know how to do the same in powershell?
I tried
Start-Process -FilePath "C:\Program Files\SAS\JMPPRO\14\jmp.exe" -ArgumentList "C:\script.jsl"
With no luck.
Actually what you wrote should work.
I use this:
$JMP_path = "C:\Program Files\SAS\JMP\15\Jmp.exe"
$JMPScriptPath = 'C:\MyScript.jsl'
Start-Process -FilePath $JMP_path -ArgumentList ("`""+$JMPScriptPath+"`"") -WaitWhat I would like to add to this is to pass another variable into the script. Any idea how to do that?
I've been using environment variables; just set it in powershell then get it in JSL.
Yes, I ended up doing the same thing. I create a ENV variable (it is local to that PowerShell session I believe) and immediately ready it with JMP that is launched from the same PowerShell session.