Reputation: 14776
I have a field called "1why". When I run this code
Me.1why.SetFocus
I get "Compile error. Expected: =". I'm sure it has to do with the name of my control beginning with a number, in fact if I rename it to "a1why" it works.
The most quick solution would be to rename my control however I would like to know how to fix it. I've tried putting the name between "" and () but this produces another serie of different errors.
Upvotes: 1
Views: 36
Reputation: 55831
If you can fix, it would be with brackets:
Me![1why].SetFocus
But do rename it anyway.
Upvotes: 1