New PC and my code doesn't run...

  • Thread starter Thread starter Chris Gorham
  • Start date Start date
C

Chris Gorham

Hi,

I have a new PC & I'm running code in a workbook that previously was
fine...Excel 2003 enviroment as before.
Now the VBA editor is kicking out an error for every variable that hasn't
been dimensioned.
Ok. I've been lazy and not inserted an Option Explicit to force dimensioning
in this code in the past.
Strangely though other code works fine and a brief test with a 3 line
routine worked ok...
Anybody got any suggestions as to what may have happened...

Chris
 
In the VB Editor, open the Tools | Options menu.
Is the second item "Required Variable Declaration" checked ? This is
equivalent to Option Explicit
Try unchecking it
best wishes
 
From the VBA Menu:

Tools > Options... > Editor > and clear the require variable declaration
checkbox
 
I belive all that option does is automatically put "Option Explicit" at the
top of any *new* modules.
It doesn't enforce declariation directly.

Tim
 
Back
Top