是什么导致错误“The ResolveManifestFiles”任务意外失败。路径中的非法字符

时间:2008-09-19 14:16:27

标签: c# build

The "ResolveManifestFiles" task failed unexpectedly.
System.ArgumentException: Illegal characters in path.
   at System.Security.Permissions.FileIOPermission.HasIllegalCharacters(String[] str)
   at System.Security.Permissions.FileIOPermission.AddPathList(FileIOPermissionAccess access, AccessControlActions control, String[] pathListOrig, Boolean checkForDuplicates, Boolean needFullPath, Boolean copyPathList)
   at System.Security.Permissions.FileIOPermission..ctor(FileIOPermissionAccess access, String[] pathList, Boolean checkForDuplicates, Boolean needFullPath)
   at System.IO.Path.GetFullPath(String path)
   at Microsoft.Build.Tasks.Deployment.ManifestUtilities.Util.RemoveDuplicateItems(ITaskItem[] items)
   at Microsoft.Build.Tasks.ResolveManifestFiles.set_NativeAssemblies(ITaskItem[] value)

The "NativeAssemblies=@(NativeReferenceFile);@(_DeploymentNativePrerequisite)" parameter for the "ResolveManifestFiles" task is invalid.

The "ResolveManifestFiles" task could not be initialized with its input parameters.

1 个答案:

答案 0 :(得分:5)

我得到了相同的构建错误,直到我允许VFP在构建后自动注册我的COM库。在我这样做之后,我不得不从我的项目中删除对.dll的引用并重新添加它,然后我的项目构建并运行文件。

如果您遇到此问题,可能需要查看以确保您没有对未注册的本机库的引用。要手动注册这样的.dll,请使用Regsvr32 utility