var shell = new ActiveXObject("WScript.Shell");剧本写得很好。Appli.exe放在C:\程序中.shell.CurrentDirectory给了C:\Users\ABC\Desktop。所以WorkingDir不可能是答案,为什么它在WScript.Shell中工作,为什么它不能在CMD中工作。那么,WScript
我有一个我写的Python脚本,可以从命令行调用它。我正在编写一个GUI包装器,但不想更改main函数。在图形用户界面代码中,我使用subprocess.run(['./executable.py', input])调用脚本,但是输入在executable.py的sys.argv列表中不可见。usr/bin/env python
# script to test using sys.a