【发布时间】:2014-05-10 07:41:37
【问题描述】:
我有创建 ftp 站点 this 的 powershell 脚本 如何使用设置工厂程序在启动时运行此脚本
【问题讨论】:
我有创建 ftp 站点 this 的 powershell 脚本 如何使用设置工厂程序在启动时运行此脚本
【问题讨论】:
启动时(设置开始前)
runscript("NameOfYourPowerShell.ps1");
function runscript(path)
l1="C:\\WINDOWS\\system32\\windowspowershell\\v1.0\\powershell.exe C:\\"
l2=path
file = io.open("c:\\runscript.bat","w");
file:write(l1..l2);
file:close("c:\\runscript.bat");
Shell.Execute("c:\\runscript.bat", "", "", "", SW_HIDE,true);
File.Delete("c:\\runscript.bat");
end
【讨论】: