我尝试直接从互联网上复制源代码,因为下面发现错误,我无法构建/调试整个文件。
请帮助
Error occurred while restoring NuGet packages: System.ArgumentException: The path is not of a legal form. at System.IO.Path.NormalizePath(String path, Boolean fullCheck, Int32 maxPathLength,Boolean expandShortPaths)
at System.IO.Path.GetDirectoryName(String path)
at NuGet.VisualStudio.VsUtility.GetNuGetSolutionFolder(Solution solution)
at NuGet.VsEvents.PackageRestorer.UsingOldPackageRestore(Solution solution)
at NuGet.VsEvents.PackageRestorer.BuildEvents_OnBuildBegin(vsBuildScope Scope, vsBuildAction Action).
1>------ Build started: Project: LaserRange, Configuration: Debug Win32 ------
1>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppBuild.targets(369,5): error MSB8031: Building an MFC project for a non-Unicode character set is deprecated. You must change the project property to Unicode or download an additional library. See http://go.microsoft.com/fwlink/p/?LinkId=286820 for more information.
==========构建:0成功,1失败,0最新,0跳过==========}
答案 0 :(得分:19)
右键单击您的解决方案,转到属性并将项目属性设置为使用Unicode。
答案 1 :(得分:19)
问题:我在哪里“将项目属性更改为Unicode ”?
回答:
对于C ++,
右键单击项目,然后选择属性,(或Alt-Enter) 属性页应该会打开
在配置属性
下常规强>
[ - ] 项目默认值
**Character Set** : Use Multi-Byte Character Set
- 更改为 -
**Character Set** : Use Unicode Character Set
发现它的痛苦。
答案 2 :(得分:13)
您需要安装MFC MBCS DLL加载项如您的错误中所述。 请参阅以下链接 http://msdn.microsoft.com/library/dn251007.aspx
答案 3 :(得分:1)
在Visual Studio中构建解决方案时遇到了相同的问题,并且在以下组件中安装时得到解决: