06-02-2023, 09:33 PM
Quote:and ironically Option _Explicit makes no difference in the example Dimster gave us
Not sure what you mean B .... The example with NO Option _Explicit runs fine with no error, but if you place Option _Explicit at the beginning of that code you get an error warning of an undefined variable.
Also Kernelpanic ... you mentioned " If it is misspelled, the following happens ".... actual my comments were if it "misused". I suppose that's splitting hairs because I do often misspell an often used variable which I believe you are pointing out Option _Explicit is ideal to catch. But the point I was trying to make, is that there are number of control variables ( ie For x = 1 to 10, or For i = ?? to ??), these control variables I don't think are usually Dimensioned and a program can have a ton of them. Option _Explicit seems to force you to Dimension them.