VBA upper case letters stopped working

T

Tony_VBACoder

I don't know what you would call this, but all of a sudden
the automatic caps of letters in a VB command is not
working. For instance, when I type "vbcrlf" and move off
this word, Access used to automatically change it
to "vbCrLf", where the "C" and "L" are changed to upper
case. All of sudden, this has stopped working and my word
stays "vbcrlf" - and it changed this throughout my entire
project, except of course where I had commented out some
code.

Any idea why this is happening and how I can get it to go
back? I have tried compiling and compacting the database,
with no luck.
 
L

Lynn Trapp

Well, now you done gone and stumped me. I can't recreate it, even removing
all the references that it will allow me to remove.
 
T

Tony_VBACoder

Very strange indeed...however, the following will work,
it's just the "vbcrlf" that has all of sudden stopped
working - notice the vbOK, vbOKOnly and vbYesNo works fine
(I typed them all in lowercase, and they automatically
switched, except the vbcrlf).

vbOK
vbcrlf
vbOKOnly
vbYesNo

By the way...this is Access 2002 SP2
 
L

Lynn Trapp

Tony,
Is there any chance that you misspelled vbCrLf and entered a number 1 or an
upper case I. I'm grabbing at straws here now. I'm on A2K2 SP2 also.
 
A

Andy Williams

This happens on my copy of Access 2000 too but only if I mistakenly Declare
a variable called vbcrlf.

After I declare vbcrlf it doesn't matter that I delete the declaration it
always appears in code as vbcrlf even after a Compact and Repair.
 
T

Tony_VBACoder

I have not declared a variable named "vbcrlf", nor did I
misspell vbcrlf. This is very strange and I'd really like
to get an answer to this.

Another strange find is, if I go into a different database
and I type "vbcrlf", it converts it to "vbCrLf", which is
how I expect it to be.
 
Top