gpt4 book ai didi

syntax - 正确的 InstallUtil 文件语法路径?

转载 作者:行者123 更新时间:2023-12-04 02:06:30 25 4
gpt4 key购买 nike

我正在尝试使用批处理文件安装 Windows 服务,我们称之为“installservice.bat”。在文件中,我有以下命令:

C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe -i ".\MyService.exe"
暂停

当我执行批处理文件(在 Vista 上以管理员身份运行)时,我得到以下信息:

初始化安装时发生异常:
System.IO.FileNotFoundException: 无法加载文件或程序集 'file:///C:\Win
dows\system32\MyService.exe' 或其依赖项之一。系统不能
ind 指定的文件..

实际服务位于 C:\Services\MyService.exe。 “.\MyService.exe”部分应该是什么才能正常运行?

最佳答案

为什么不给 InstallUtil 提供完整路径?

关于syntax - 正确的 InstallUtil 文件语法路径?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1276578/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com