Access Denied while running C++ code in Visual Studio Code

Kumud Verma 1 Reputation point
2021-06-29T06:58:16.67+00:00

As i click on run code button of code runner extension of vsc
It create a .exe file which is deleted by mAcfee Antivirus 110084-screenshot-211.png

C++
C++
A high-level, general-purpose programming language, created as an extension of the C programming language, that has object-oriented, generic, and functional features in addition to facilities for low-level memory manipulation.
3,537 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Viorel 112.5K Reputation points
    2021-06-29T07:39:46.24+00:00

    Check the documentation of Antivirus about file and folder exceptions: https://www.bing.com/search?q=mcafee+exclusions. Add your a.exe file or folder to the list of of exclusions.

    By the way, you can also use Visual Studio for such programs.


  2. RLWA32 40,571 Reputation points
    2021-06-29T14:26:54.933+00:00

    McAfee consumer products do not support folder exclusions. Other than removing McAfee another option is to disable real-time scanning during your development activities. Regarding folder exclusions, refer to excluding folder

    0 comments No comments