UCase validation works in one database but not in other

  • Thread starter Thread starter Hugh self taught
  • Start date Start date
H

Hugh self taught

Hi All,

I must be missing a setting somewhere. In 2 very similar databases on the
same machine I have a text box where I've set the Validation Rule to
=UCase([Nat_Reg]). In the one database it converts the input to uppercase in
the related table but it doesn't in my other database.

I have subsequently changed my approach to using KeyAscii =
Asc(UCase(Chr(KeyAscii))) on key press, but was wondering why the first
method worked in one database & not the other
 
The validation rule does not change data. It only checks if the data
input into the control meets a rule. Also, as a validation rule this
will not check whether something is uppercase or not. In Access data is
not case-sensitive.

Perhaps you meant something else.

'====================================================
John Spencer
Access MVP 2002-2005, 2007-2009
The Hilltop Institute
University of Maryland Baltimore County
'====================================================
 
Hi All,

I must be missing a setting somewhere. In 2 very similar databases on the
same machine I have a text box where I've set the Validation Rule to
=UCase([Nat_Reg]). In the one database it converts the input to uppercase in
the related table but it doesn't in my other database.

I have subsequently changed my approach to using KeyAscii =
Asc(UCase(Chr(KeyAscii))) on key press, but was wondering why the first
method worked in one database & not the other

The Validation Rule property is not case sensitive and only checks if
the value meets the Validation Rule, it doesn't change the value to
meet it.

Most likely you have code in the AfterUpdate event in one of the
databases that changes the value and not in the other.

Something like:
Me.[ControlName] = UCase([ControlName])
 
Back
Top