Text Box help


Posted by Beginner Bob on November 28, 2000 2:21 PM

I have created a userform which contains several text boxes etc. I would like help on 2 issues
1. 3 of the text boxes are for number entries (specifically money - 2 for entry, 1 for
autofill/entry), and I need them to only allow 2 digits after the decimal (Ex. 15.50). Is
there a way to do this in the properties window? How do I do this?

2. I modified the userform, and inserted "textbox6" in between "textbox3"
and "textbox4". How do I go about changing the tab order for these textboxes so the focus is
on "textbox6" then "textbox4" etc. after tabbing from "textbox3" without changing the names
around?

Thanks for any help I can get.

Posted by Marianne on November 28, 2000 2:34 PM

I can't believe that I can actually answer a question. I just learned the answer to your question #2 yesterday while taking lessons from a free online tutorial. Anyway, here is the answer to your second question:

"You do not always place controls on a form in the same order in which you want to set the focus. Therefore, controls that can receive the focus support a property called the TabIndex property. The first control in the focus order has a TabIndex property of 0, the second control in the focus order has a TabIndex of 1, and so on. If you place controls on the form and then later want to modify the focus order, you need to change the controls' TabIndex property values."

I hope this helps.

Marianne



Posted by Marianne on November 28, 2000 2:34 PM

I can't believe that I can actually answer a question. I just learned the answer to your question #2 yesterday while taking lessons from a free online tutorial. Anyway, here is the answer to your second question taken from http://www.itknowledge.com/reference/archive/0672310643/htm/ch04.htm#Heading8 :

"You do not always place controls on a form in the same order in which you want to set the focus. Therefore, controls that can receive the focus support a property called the TabIndex property. The first control in the focus order has a TabIndex property of 0, the second control in the focus order has a TabIndex of 1, and so on. If you place controls on the form and then later want to modify the focus order, you need to change the controls' TabIndex property values."

I hope this helps.

Marianne