Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Uppercase and Next/Prvs Cmd buttons

Posted on 2003-02-21
5
Medium Priority
?
232 Views
Last Modified: 2012-06-21

I was just wondering about a couple of things.

Firstly I would like to force a text box to uppercase, or at least store the data entered in uppercase. I'm sure this is very simple but I can't for the life of me figure it out!

Secondly I would like a command button to continuously scroll through records (like the navigation buttons). I do not want the navigation buttons to be shown on my form therefore scrolling through records is currently very slow (click click click etc)!!!

Thanks all.
0
Comment
Question by:Gustus
4 Comments
 
LVL 41

Accepted Solution

by:
shanesuebsahakarn earned 120 total points
ID: 7992739
For your first problem, set the InputMask of the text box to:
>

For your second problem, the only way I can think to do this is to combine the MouseDown, MouseUp and Timer events. In the MouseDown event of the command button, set a global form variable to true. In the Timer event, which you can set to fire at an interval to suit yourself, check if that variable is true. If it is, then go to the next record. In the MouseUp event, set the variable to false.
0
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 7992763
two possibilities for #1)

Use the Lost Focus Event or the KeyPress Event:

Private Sub txtTextBox_LoastFocus()
   txtTextBox.Text = UCase$(txtTextBox.Text)
End Sub


or

Private sub TxtTextBox_KeyPress(KeyAscii as Integer)
   If keyAscii >= Asc("a") and KeyAscii <= asc("z") then
       KyeAscii = KeyAscii -32
   End If
End Sub

The first will allow lowercase entry, and then convert the ENTIRE text to Upppercase, when the user tabs off the text box.

The second will convert the lower case to uppercase 'on the fly', so the user will not be aware that anything has taken place.

AW
0
 

Author Comment

by:Gustus
ID: 7993733

Thanks both but I am still struggling with the scrolling record button. Any ideas anyone?
0
 
LVL 18

Expert Comment

by:1William
ID: 8708038
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
Accept question, points to shanesuebsahakarn
Please leave any comments here within the next seven days.
 
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
 
1William
EE Cleanup Volunteer
0

Featured Post

Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

Question has a verified solution.

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

If you’re using QODBC to update QuickBooks data from Microsoft® Access but Access is not showing the updated data, you could have set up QODBC incorrectly.
In a use case, a user needs to close an opened report by simply pressing the Escape (Esc) key. This can be done by adding macro code in Report_KeyPress or Report_KeyDown event.
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…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

577 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