LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming,microsoft.public.excel.misc
external usenet poster
 
Posts: 9
Default Excel 97 - VB question

I have a form with some textboxes on it (textbox1 and textbox2). When the
user tabs from textbox1 to the textbox2, I validate the contents of the
textbox1 in the textbox1_AfterUpdate event handler. If the content textbox1
is invalid, I want to keep the cursor in textbox1, rather than tabbing to
textbox2.

I have tried using textbox1.SetFocus method in the textbox1_AfterUpdate and
textbox2_Enter event handlers. Neither worked.

What is a good way to do this? Thanks.


Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"