我在VisualStudio 2010中构建了一个C++Windows应用程序,带有一个安装项目来创建一个.MSI,当用户有一个本地的“cc>文件夹”时,它安装得很好,但是当其My Documents文件夹位于网络驱动器上时失败。
当在本地安装时,安装程序会在其My Documents文件夹中创建ProjectData文件夹,但当我尝试将My Documents安装到网络位置的系统时,.msi会失败,并显示My Documents错误消息。在安装程序日志文件中,当安装程序创建描述cannot access network locationProject目录的属性时,而不是在尝试创建和填充这些目录时,似乎会发生故障。
有人知道我如何避免、解决或从这个错误中恢复吗?
现在安装失败了,我的文档在网络上的系统会回滚。谢谢。
从MSI日志:

"The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 2835. The arguments are: ErrorIcon, ErrorDialog,
Error 1606. Could not access network location \\TOMVEE-W7PC\Users\W8RemoteUserDocs\\eQUEST 3-65 Projects\.
MSI (c) (38:64) [13:13:34:987]: Note: 1: 2262 2: Error 3: -2147287038
MSI (c) (38:64) [13:13:34:987]: Product: eQUEST 3-65 -- Error 1606. Could not access network location \\TOMVEE-W7PC\Users\W8RemoteUserDocs\\eQUEST 3-65 Projects\.

MSI (c) (38:64) [13:13:34:989]: Note: 1: 1314 2: \\TOMVEE-W7PC\Users\W8RemoteUserDocs\\eQUEST 3-65 Projects\
MSI (c) (38:64) [13:13:34:989]: Note: 1: 1606 2: \\TOMVEE-W7PC\Users\W8RemoteUserDocs\\eQUEST 3-65 Projects\
MSI (c) (38:64) [13:13:34:989]: Note: 1: 2262 2: Error 3: -2147287038
MSI (c) (38:BC) [13:13:34:991]: Note: 1: 2262 2: Error 3: -2147287038
DEBUG: Error 2835:  The control ErrorIcon was not found on dialog ErrorDialog
The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 2835. The arguments are: ErrorIcon, ErrorDialog,
Error 1606. Could not access network location \\TOMVEE-W7PC\Users\W8RemoteUserDocs\\eQUEST 3-65 Projects\.
MSI (c) (38:64) [13:13:39:006]: Note: 1: 2262 2: Error 3: -2147287038
MSI (c) (38:64) [13:13:39:006]: Product: eQUEST 3-65 -- Error 1606. Could not access network location \\TOMVEE-W7PC\Users\W8RemoteUserDocs\\eQUEST 3-65 Projects\.

MSI (c) (38:64) [13:13:39:007]: Note: 1: 1606 2: \\TOMVEE-W7PC\Users\W8RemoteUserDocs\\eQUEST 3-65 Projects\
MSI (c) (38:64) [13:13:39:007]: Note: 1: 2262 2: Error 3: -2147287038
MSI (c) (38:BC) [13:13:39:009]: Note: 1: 2262 2: Error 3: -2147287038

我不认为丢失的错误图标是相关的,但也许?

最佳答案

无论是只为我安装还是为所有用户安装,都会出现此问题。
我制作了一个小应用程序来测试权限,如果权限不足,我会更新它们,但这仍然不能解决问题。
但是,在手动测试的过程中,我发现在目录路径中间有一个额外的“\”导致了这个问题,比如“\tomvee-w7pc\users\w8remoteuserdocs\equest 3-65 projects”。这个额外的斜线是因为安装项目属性中用于文件夹默认位置的[PersonalFolder]已经生成了“\”,然后我还在属性值中添加了斜线。这个额外的斜杠没有在本地安装中引起问题,但确实在网络位置上的安装中引起问题,可能是因为“\”在网络目录中有其他含义。
所以问题是错误地构造了目录路径,而不是权限。仅仅是在一个奇怪的机会发布这个答案,其他人也在同一个问题上挣扎。
感谢响应者,
汤姆

关于windows - 网络驱动器上的安装目录时,Windows Installer无法访问网络位置,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/22184138/

10-13 09:10
查看更多