"Microsoft Defender SmartScreen prevented an unrecognized app from starting" impedes me from freely editing or running my desktop startup batch file

I put a file named "Desktop_startup_aaa.cmd" ("the Batch File") in my Windows startup folder.

When I reboot, and the Batch File is triggered by being in my startup folder, I get the warning, "Microsoft Defender SmartScreen prevented an unrecognized app from starting" ("the Annoying Obstruction-Warning"), and I have to tell Windows that it's okay to run the Batch file, and I find the delay and the required keystrokes annoying.

My default text editor is EditPad Pro (fullname/full path = "C:\Program Files\Just Great Software\EditPad Pro 8\EditPadPr08.exe").

When I right-click on my Batch file in Windows Explorer and choose "Edit", I get the Annoying Obstruction-Warning.

If I click on the "More info" link, the warning window expands to include the following information:

App: Desktop_startup_aaa.cmd

Publisher: Unknown publisher

Can I tell Windows that I'm the "Publisher", whatever that is?

I also get the Annoying Obstruction-Warning if I right-click on the file, and choose:

1. Edit with SublimeText; or

2. Edit with Visual Studio Code.

But I do not get the Annoying Obstruction-Warning when I choose "Edit with Notepad ++".

I have no idea why the option to "Edit withNotepad++" is somehow exempt from triggering the Annoying Obstruction-Warning.

I am running Windows 10 Pro with 64 GB ram. I also am running Malwarebytes for virus protection.

Any suggestions would be much appreciated.

Marc

|

Dear Marc B. Hankin,

Welcome to the Microsoft Community

I understand that the "Microsoft Defender SmartScreen" warning can be quite frustrating, especially when it interferes with your workflow by preventing you from freely editing or running your batch file. Let's try to resolve this issue by adjusting the security settings and making some configurations.

 

Here are potential solutions:

 

Adjust SmartScreen Settings
Press Win + I to open Settings.
Go to Update & Security > Windows Security.
Click on App & browser control.
Under Check apps and files, select Warn (recommended for security) or Off (if you prefer to completely disable it).

 

Allow the Batch File through SmartScreen
Right-click on the batch file and select Run as administrator.
When the SmartScreen warning appears, click on More info.
Click on Run anyway.
Doing this once can sometimes flag the batch file as safe in future executions.

 

Exempt the Batch File from Scans
Open Windows Security.
Go to Virus & threat protection.
Scroll down and click on Manage settings under Virus & threat protection settings.
Scroll down and click on Add or remove exclusions under Exclusions.
Click Add an exclusion and select File.
Navigate to your batch file and select it.

 

Check File Permissions
Right-click on the batch file and select Properties.
Under the General tab, if there is an Unblock checkbox next to the security message "This file came from another computer and might be blocked to help protect this computer", check it and click Apply.

 

If you have any further questions or need more assistance, please let me know. I'd be happy to help!

Best Regards,

Martin | Microsoft Community Support Specialist

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

Dear Martin:

Thank you for the valuable education. You included the option I seek which is to "Exempt the Batch File from Scans".

However, my Windows 10 Pro doesn't include the option "Manage settings" you mentioned.
When I opened the Virus & threat protection settings, here's what I saw:

Image
Image

I did configure exceptions in Malwarebytes, as shown in the following image:

Image

"Desktop_startup_aaa.cmd" is a file that:

  1. I inadvertently omitted showing in the above image of the Allow list.

  2. I did include it in the Allow list, but I don't think I should overload you with yet another image showing where "Desktop_startup_aaa.cmd" is listed in the Allow list.

Nevertheless, when I right-click on "Desktop_startup_aaa.cmd" and select "Edit", the Annoying Obstruction-Warning, "Microsoft Defender SmartScreen prevented an unrecognized app from starting", shows up and requires me to use the mouse and click twice before I can start editing.

Thank you for reading this. I'll appreciate any suggestions.

Marc,

Dear Marc B. Hankin,

Welcome to the Microsoft Community

I understand that the "Microsoft Defender SmartScreen" warning can be quite frustrating, especially when it interferes with your workflow by preventing you from freely editing or running your batch file. Let's try to resolve this issue by adjusting the security settings and making some configurations.

 

Here are potential solutions:

 

Adjust SmartScreen Settings
Press Win + I to open Settings.
Go to Update & Security > Windows Security.
Click on App & browser control.
Under Check apps and files, select Warn (recommended for security) or Off (if you prefer to completely disable it).

 

Allow the Batch File through SmartScreen
Right-click on the batch file and select Run as administrator.
When the SmartScreen warning appears, click on More info.
Click on Run anyway.
Doing this once can sometimes flag the batch file as safe in future executions.

 

Exempt the Batch File from Scans
Open Windows Security.
Go to Virus & threat protection.
Scroll down and click on
Manage settings under Virus & threat protection settings.
Scroll down and click on Add or remove exclusions under Exclusions.
Click Add an exclusion and select File.
Navigate to your batch file and select it.

 

Check File Permissions
Right-click on the batch file and select Properties.
Under the General tab, if there is an Unblock checkbox next to the security message "This file came from another computer and might be blocked to help protect this computer", check it and click Apply.

 

If you have any further questions or need more assistance, please let me know. I'd be happy to help!

Best Regards,

Martin | Microsoft Community Support Specialist

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

Dear Martin D:

Could you please tell me if you did not reply to my March 28 reply to your March 22 Answer (which took a lot of your time and was very kind and thoughtful of you) because I did something wrong in my March 28 reply?

If I did something wrong, please tell me what I did wrong so I know not to do it again.

Thank you again,

Marc

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

 
 

Question Info


Last updated April 19, 2025 Views 416 Applies to: