A friend asked me to look at some of his VBA code. When I tried running it, it moaned about a variable not being defined so I just added it in a dim statement. When I tried running it again, it kept on moaning until I had declared every variable that was used. But then he told me that that code had been running on his machine for the last two years and he never had to declare those variables.
Is there a switch somewhere in Excel that allows you to get away with undeclared variables?
Is there a switch somewhere in Excel that allows you to get away with undeclared variables?