Re: How to have filled data in field started with CAPITAL?
- From: "Allen Browne" <AllenBrowne@xxxxxxxxxxxxxx>
- Date: Fri, 22 Jul 2005 10:44:09 +0800
If you would like the keystrokes to be converted to upper case as the user
types them:
1 Set the control's On Key Press property to:
[Event Procedure]
2. Click the Build button (...) beside this.
Access opens the code window.
3. Between the "Private Sub..." and "End Sub" lines, enter:
If KeyAscii >= 97 And KeyAscii <= 122 Then
KeyAscii = KeyAscii - 32
End If
BTW, do NOT simply use > in the Format property. That makes Access to
display the value in upper case, but does not store the values in upper
case.
--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.
"AA Arens" <bartvandongen@xxxxxxxxx> wrote in message
news:1121997162.802750.77720@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
>I want the filled data in a field starts always with a Capital
> character.
>
> Private Sub myfield_AfterUpdate()
> Me!myfield= UCase$(Left$(Me!myfield, 1))
> End Sub
>
> caused the cursor to be moved to the left / last character.
>
> But, it caused also that only 1 character is filled after update:
> Like:
> keyboard > K
> and not
> keyboard > Keyboard
>
> How to solve it?
.
- Follow-Ups:
- Re: How to have filled data in field started with CAPITAL?
- From: Steve Jorgensen
- Re: How to have filled data in field started with CAPITAL?
- References:
- How to have filled data in field started with CAPITAL?
- From: AA Arens
- How to have filled data in field started with CAPITAL?
- Prev by Date: Re: Releasing Object Variables
- Next by Date: Re: Access 2003 missing the intranet or the website
- Previous by thread: Re: How to have filled data in field started with CAPITAL?
- Next by thread: Re: How to have filled data in field started with CAPITAL?
- Index(es):
Relevant Pages
|