Turn Off Syntax/Compile Error Alerts in Visual Basic Editor
Writing VBA Code Can’t Be This Annoying, Can It?
When I first started coding in the Visual Basic Editor (VBE) I would always get so annoyed with the message box alerts that would pop up every time I didn’t use proper code syntax. This caused me to get distracted since every time I didn’t type something in properly I would get an error alert and have to click the OK button (usually occurred every other minute).
Being new to using the Visual Basic Editor, I thought this was just normal and I had to live with the annoying pop-ups. After I got more comfortable with the editor I started playing around with the options and stumbled upon a setting that I am so thankful exists! This setting allowed me to turn off the annoying syntax error message alerts and I have not seen one since!
Steps To Get Rid Of The Syntax Error Alerts
Step 1: In the Visual Basic Editor (shortcut: Alt + F11) open the Tools menu and select Options…
Step 2: In the Options dialog box, ensure the Auto Syntax Check checkbox is NOT checked in the Code Settings section. This turns off the error messages while still coloring incorrect syntax code with red font.
Hit the OK button and you should be error message free from now on! Woohoo!!
My Question To You!
So I’m curious, was I just naive or did it take you a long time to figure out how to rid your life of VBA Error Alerts? Leave a comment below and let me know how long it took you!
After 10+ years of creating macros and developing add-ins, I've compiled all the hacks I wish I had known years ago!
Adding A Logo or Image To A Spreadsheet Header/Footer
What This VBA Code Does If you are using Headers or Footers for your spreadsheets, the chances are you're going...
VBA Set Shape Variable To Selected Shape
What This VBA Code Does The following code will show you how to take the currently selected shape in an...
Chris is a finance professional and Excel MVP recognized by Microsoft since 2016. With his expertise, he founded TheSpreadsheetGuru blog to help fellow Excel users, where he shares his vast creative solutions & expertise. In addition, he has developed over 7 widely-used Excel Add-ins that have been embraced by individuals and companies worldwide.