>I have a series of textboxes to tab through. The textboxes contain numeric data so I set text alignment to right justify. When I tab through the fields the cursor is being placed on the left side of the data instead of the right. How do I change that? Also, is there a way to have all of the text highlighted instead of just a cursor?
To have the data highlighted in a textbox, you need to add this code:
Private Sub Text1_GotFocus()
With Text1
.SelStart = 0
.SelLength = Len(.Text)
End With
End Sub
Éric Moreau, MCPD, Visual Developer - Visual Basic MVP
Conseiller Principal / Senior Consultant
Moer inc.
http://www.emoreau.com