+ Reply to Thread
Results 1 to 3 of 3

exit loop when find value?

  1. #1
    Registered User
    Join Date
    09-14-2010
    Location
    Boston
    MS-Off Ver
    Excel 2007
    Posts
    22

    exit loop when find value?

    Hi all,

    I need your help for a simple question.
    I have a drop down combobox with lots of name for user pick : Brian, Danny, Tommy, Hennry.....and more

    In columme A sheet1 has all therandom name like

    Brian
    Tommy
    Danny
    Hennry
    ..
    Tommy
    ....
    ....
    lost of them repeating each other.

    I would like to have an exit (stop) the loop when it found the first name match, not go through the whole columme to look for other matches (more matches if keep looping)
    Here the code: sht is sheet1
    Please Login or Register  to view this content.
    How can i stop when it finds the name?
    Thanks

  2. #2
    Forum Expert
    Join Date
    10-10-2008
    Location
    Northeast Pennsylvania, USA
    MS-Off Ver
    Excel 2007
    Posts
    2,387

    Re: exit loop when find value?

    sweetboy02125,

    Try:


    Please Login or Register  to view this content.
    Have a great day,
    Stan

    Windows 10, Excel 2007, on a PC.

    If you are satisfied with the solution(s) provided, please mark your thread as Solved by clicking EDIT in your original post, click GO ADVANCED and set the PREFIX box to SOLVED.

  3. #3
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: exit loop when find value?

    Hi sweetboy02125

    Or rhis
    Please Login or Register  to view this content.
    John
    John

    If you have issues with Code I've provided, I appreciate your feedback.

    In the event Code provided resolves your issue, please mark your Thread as SOLVED.

    If you're satisfied by any members response to your issue please use the star icon at the lower left of their post.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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