• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

How to put "Option Explicit" by default

KishorKK

Member
Hi All,

1. In VBA how to put "Option Explicit" by default.

2. After saving VBA i'm getting this, how to turn off this, some one help me

upload_2016-11-13_19-6-14.png
 
1. In the Visual Basic Editor, click on Tools and then click on Options.

2. Check Require Variable Declaration.

require-variable-declaration.png


Note: Option Explicit will not be added automatically to existing Excel files. Simply type in Option Explicit yourself if you want to use it.

Question two should have its own post as it will not show in any search as it is buried in a non related question so anyone searching for this answer will not find it.



DocN4.jpg



Step by step instructions (for 2007):

  1. Office orb
  2. Excel options
  3. Trust Centre
  4. Trust Centre Settings...
  5. Uncheck Remove personal information from file properties on save
  6. OK
  7. OK

.
.
 
Back
Top