+ Reply to Thread
Results 1 to 5 of 5

How to return back to textbox after

  1. #1
    Registered User
    Join Date
    08-10-2012
    Location
    Slovenia
    MS-Off Ver
    Excel 2007
    Posts
    24

    How to return back to textbox after

    Hello,

    I have quite some text-boxes for entering data. For user to be efficient i created _Exit event with setting focus on next textbox.
    So user can just move to next textbox only with return key, no need to use mouse.
    Now comes the problem. If user makes mistake and wants to correct value in previous textbox, textbox cannot be selected because there is _Exit event on next text box which moves focus to next textbox so long that it comes to commandbutton, where it clears all textboxes and set focus on first textbox for new entries.

    In the userform there is also listview to immediately reflect entered values.
    Does anyone have an idea how to make possibility to be able to correct values in previous textboxes, before coming to commandbutton.

    Please Login or Register  to view this content.
    Thanks for any suggestion

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: How to return back to textbox after

    Please upload a workbook or a representative cut down copy, anonymised if necessary. It is always easier to advise if we can see your request in its context.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Expert
    Join Date
    06-25-2009
    Location
    Sofia, Bulgaria, EU
    MS-Off Ver
    Excel 2003-2013
    Posts
    1,290

    Re: How to return back to textbox after

    There is no need to write exit event handler. Just use Tabindex property of the TextBox (or any control).
    If you are pleased with a member's answer then use the Star icon to rate it.

  4. #4
    Registered User
    Join Date
    08-10-2012
    Location
    Slovenia
    MS-Off Ver
    Excel 2007
    Posts
    24

    Re: How to return back to textbox after

    I attached the workbook.
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    08-10-2012
    Location
    Slovenia
    MS-Off Ver
    Excel 2007
    Posts
    24

    Re: How to return back to textbox after

    Thanks buran, it helped

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Edit textbox in userform and write back to database using AfterUpdate
    By nigelog in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-30-2016, 05:27 AM
  2. How to set cursor back to textbox on a userform when validating data?
    By excelkann in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-23-2016, 03:48 AM
  3. Double click row to return data to userform for edit then return back to sheet
    By MattRSJ in forum Excel Programming / VBA / Macros
    Replies: 19
    Last Post: 01-31-2014, 06:05 AM
  4. [SOLVED] Fill textbox from another textbox when enter and car return
    By Alendi in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-11-2013, 03:16 PM
  5. vba cmd button to assign for edit section of textbox values return back to acurate cell
    By breadwinner in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-26-2013, 05:01 AM
  6. Changing Textbox From Grey to Enabled and Back Again With Option Buttons
    By stuu3270 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-24-2013, 04:59 AM
  7. Moving focus back to first textbox
    By LisaPatch in forum Excel Programming / VBA / Macros
    Replies: 17
    Last Post: 11-01-2011, 10:23 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1