Hi!
In the KeyPress event of textbox put following:
if m.nKeyCode = 127 AND nShiftAltCtrl = 0 AND this.SelStart=0
nodefault
endif
I recommend to create a class for all yoru Text Boxes and use that class on all fiorms instead of default text box control. So you can place above code in the base class for all textboxes - in a single place, not in every text box on every form.
Hope this helps.
>I have a few Textbox. I using 'Enter' to go to another TextBox. If I want to delete the contain of the textbox, I using the 'backspace' to delete. When I press to many time of 'BackSpace', It will jump to the previous textbox. Can I stop the cursor from moving back to prevous textbox.
>
>Thanks
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.comICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs
It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.