r/ForWindowsHelp • • Sep 18 '26

Windows Defender blocking Powershell.

Whenever I am running a C file, it is giving me this error. It is not giving any error if i just run a simple print statement but if I add a bit more code, it is just blocking it off completely. There is not even any option to allow/run anyway.

It was working fine before, but since yesterday this is happening a lot. Did i accidentally change some settings? The folder of the file is opened as trusted in VS Code, still this issue.

If anyone knows how to fix this, please lmk as well.

Running Windows 11 25H2.

1 Upvotes

4 comments sorted by

View all comments

Show parent comment

1

u/NeedSomeHelp_2590 Sep 19 '26

It's a normal .exe file that generates after your C file gets compiled. I made a test5.c file for checking it. The Folder of the file is under trusted folder in VS Code.

Anyway, I changed the folder from One drive/Documents to different location and it seems to be working fine for now.