Solved

Force upper case text in a form

Posted on 2004-09-10
3
393 Views
Last Modified: 2008-02-01
I have a simple login dialog box that has a text box (txtUser) and a Login button (cmdLogin).  The user will type their initials in the text box then clicking the login button verifies the initials and passes the txtUser to a global public variable (gstrUser).  I would like the gstrUser text to always be upper case so when they modify a record their initials are entered in the UserID field in the form.

How can I make gstrUser always be caps???

Thanks
0
Comment
Question by:beyondt
3 Comments
 
LVL 3

Accepted Solution

by:
BrentTemple earned 125 total points
ID: 12032573
When you pass the txtUser into the gstrUser, you could switch it to uppercase.   I'm assuming the command botton runs a little bit of vb.

gstrUser = UCASE(me.txtUser)

-Brent
0
 
LVL 4

Expert Comment

by:Excalibur_Software
ID: 12032969
another place you may want to add that code might be the before update event

Private Sub Form_BeforeUpdate(Cancel As Integer)

   gstrUser = Ucase(me.txtUser)

End Sub
0
 

Author Comment

by:beyondt
ID: 12034479
Thanks!!  There are many more questions to come.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Export  Access Query To Excell 16 46
Sending email from List Data 2 51
Track name AutoCorrect info 14 46
how to address a subform in a form, from inside another subform 2 24
The first two articles in this short series — Using a Criteria Form to Filter Records (http://www.experts-exchange.com/A_6069.html) and Building a Custom Filter (http://www.experts-exchange.com/A_6070.html) — discuss in some detail how a form can be…
Experts-Exchange is a great place to come for help with solutions for your database issues, and many problems are resolved within minutes of being posted.  Others take a little more time and effort and often providing a sample database is very helpf…
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

25 Experts available now in Live!

Get 1:1 Help Now