on-internet
← Community

VS Code C++ executable repeatedly blocked by Windows Application Control policy

Stack Overflow ·

I am using Visual Studio Code on Windows 11 to write and run C++ programs. I have installed g++ (MinGW) and compile my programs using the following command: g++ OPPS.cpp -o myprogram.exe The compilation works successfully without any errors. However, when I run the executable using: .\myprogram.exe Windows PowerShell sometimes displays this error: Program failed to run: An Application Control policy has blocked this file. Initially, the program runs successfully, but when I compile and run it again, Windows blocks the executable. I have already checked Windows Security, but I cannot find any b

Comments

Sign in or sign up to comment and upvote.

No comments yet.