【问题描述】
1) 用VS2022调试运行,弹出错误对话框,显示:
--------------------------- Microsoft Visual Studio --------------------------- “projectFilePath”不能为空字符串("")或以 null 字符开头。 参数名: projectFilePath --------------------------- 确定 ?? --------------------------- |
2) 点“确定”后,调试进程其实已经启动成功,能正常运行。
3) 重启VS未能解决
【问题原因】
未知。
在网上搜到类似问题,说是和VS的“lightweight loading”特性有关(但没弄明白是个什么...)。
【解决办法】
关闭VS -> 删除程序目录下的?.vs 目录 -> 启动VS,再运行调试,正常。
The problem seems to be with the new lightweight solution loading feature of VS2017.
To fix it, first clean up:
Close Visual Studio 2017
Delete or rename the .vs folder
Reopen the solution
Afterwards, don't re-enable lightweight solution loading for that solution.
You can completely disable lightweight solution loading for all solutions in the options, but if the problem only applies to some solutions then that might be a bit heavy handed.
摘抄自:.net - Build Failure. Error: 'path' cannot be an empty string ("") or start with the null character - Stack Overflow
|