Rick;
When you reach the mid 70's, memory sometimes really sucks. After reading
your reply a number of times I had a wakeup at 3:00 am this morning thinking
that the code was to make my life a little easier. That column I believe
used to be for Zip/Postal codes. Without changing case, I would enter a
zipcode 983119667 and it would automatically convert it to 98311-9667 or a
postal code of k1e2l2 to K1E 2L2. Does this seem logical?
--
Regards
Michael Koerner
That looks like code I wrote... I don't remember it, but the coding style
appears to be mine. Anyway, what this code is doing is looking down Column M
and if a cell in that column has either a 6 or 9 character value in it (a
constant, not a formula result), then it makes the characters upper case and
inserts either a space or a dash in the "middle" depending on whether the
length was 6 or 9 characters. So, an entry like "abcdef" would become "ABC
DEF" and an entry like "abcdefghi" would become "ABCDE-FGHI". It appears
that this functionality is deliberately wanted, so removing the UCase
functionality **may** not be what you want to do. On the other hand, you may
have simply done a Clear All on the sheet and reused it for some other
purpose, forgetting that the event code was there. You have to decide which
is the case. Anyway, if the code's functionality is actually needed, then
just removing the UCase function calls would be the wrong way to go. If, on
the other hand, this sheet is being reused for a different purpose, the the
solution would be to delete the Worksheet_Change procedure in its entirety.