2015-11-19 96 views

回答

0

最簡單的方法是使用.vbs腳本來設置環境變量,然後啓動應用程序。

例如:

set ws = wscript.createobject("WScript.shell") 
set systemEnv = wshShell.Environment("SYSTEM") 
systemEnv("YourVariable") = "Your value" 
ws.run("notepad.exe"), 0, true 

標誌:

0 = Hidden 
1 = displayed 
True = Waits till command has completed before moving to next 
False = Does not wait for command to complete before moving to next 
+0

感謝米哈伊爾,我嘗試使用批處理文件來運行它。我能夠發佈批處理文件,但在嘗試下載批處理文件的ica時出現錯誤。這很容易! – nahzor