Compile and run slicer in vs2022, and the prompt “Access Denied” appears

I compiled slicer on two windows (one is win10 and the other is win11). At that time, I could compile and run slicer normally using vs2022. However, after a few days, when I compiled and ran slicer again, it prompted access denied. What’s going on? Note: The operating environment has not changed.

Do you have any other thing to show? The exact error message, a full log? Thanks!

Sorry for the late reply. This mainly prompts the following error screenshot, but I haven’t found the log yet. Whether it is compiled by cmake or ninja, this error is reported when compiled in vs2022.


I have tried running vs2022 as an administrator and then running slicer in debug, or changing the folder properties to no longer read-only, but the problem cannot be solved.

It seems that you forgot to specify the startup project, and probably the executable as well

This is explained here btw
https://slicer.readthedocs.io/en/latest/developer_guide/debugging/windowscpp.html