MaskedTextBox Help

M

Mike Fellows

I have a few masked textboxes within my application and I have the same
problem with each and everyone

If I tab to a masked textbox i have no issues, but when i click into a mask
textbox the problems arise.

when i click in it places the cursor where i click (not at the start of the
masked textbox), this forces users
to either click back to the start of the textbox or hold the left arrow key
to move back to the start

is there anyway to stop this, or even an onclick event?

Thanks

Mike Fellows
 
M

Mike Fellows

to be honest there isnt any code

i have a maskedtextbox (a standard control in vs 2005)

if i set the mask to 0000000000 (right click properties)

this will only allow me to input numbers (to a max of 10 numbers into the
control)

but when i click onto the control it will start at the posistion i click
(not at the start/left)

Cheers

Mike
 
G

Guest

....yes - the only way around it is I've written an onEntry trigger for each
textbox and in it put:

yourmaskedtextbox.selectall()

It has the effect of selecting all of the text in your textbox so the cursor
gets put at the beginning of the field. May not be what you want - but it
works in certain cases depending on your needs.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top