+ Reply to Thread
Results 1 to 6 of 6

Search and display results in userform Issue. Results are incorrect

  1. #1
    Registered User
    Join Date
    01-17-2019
    Location
    falmouth
    MS-Off Ver
    2019
    Posts
    31

    Search and display results in userform Issue. Results are incorrect

    I have a userform that searches for a product based on a unique number for example( 664907 Printers tray £40.00) this data is located in a sheet called "Stock" Column A has the unique number Column B Has the Item name And column C has the Price.

    I have created the userform to search and return the results of column B & C in two Textboxes on the userform.

    I also have a clear and add button that works perfectly , however i am struggling, sometimes the results that the userform displays are incorrect. It will jump to a different unique number after i have clicked seraph? Sometimes it will wok and other times it will not, Can anyone help/

    Here is the code i am using at present. If anyone can help me this would be great.

    Please Login or Register  to view this content.

  2. #2
    Valued Forum Contributor dmcgov's Avatar
    Join Date
    11-11-2015
    Location
    Florida, USA
    MS-Off Ver
    Office 365 Business
    Posts
    1,518

    Re: Search and display results in userform Issue. Results are incorrect

    can you upload a sample workbook?

  3. #3
    Registered User
    Join Date
    01-17-2019
    Location
    falmouth
    MS-Off Ver
    2019
    Posts
    31

    Re: Search and display results in userform Issue. Results are incorrect

    Thanks, The search button that brings up the userfom is on sheet 1, the results when you click add will be copied top sheet 2 and the stock list is where the results are found,
    if you try a couple of numbers you will notice that at first it works but then jumps to a different number and product no matter what unique id Number you put in.

    Thanks
    Attached Files Attached Files

  4. #4
    Forum Expert rorya's Avatar
    Join Date
    08-13-2008
    Location
    East Sussex, UK
    MS-Off Ver
    365 Ent Monthly Channel / Insiders Beta
    Posts
    8,903

    Re: Search and display results in userform Issue. Results are incorrect

    Code 664907 for example also appears in column H on the Stock sheet, which is what causes the issue.
    Rory

  5. #5
    Registered User
    Join Date
    01-17-2019
    Location
    falmouth
    MS-Off Ver
    2019
    Posts
    31

    Re: Search and display results in userform Issue. Results are incorrect

    Thanks, Is it that simple. lol, Wow it all works now. Is there any way to define the colums the serach takes place in and ignores the sold items ? i could always move this info on to another page i guess and still use Vlookup to check stock etc. Thankyou

  6. #6
    Forum Expert rorya's Avatar
    Join Date
    08-13-2008
    Location
    East Sussex, UK
    MS-Off Ver
    365 Ent Monthly Channel / Insiders Beta
    Posts
    8,903

    Re: Search and display results in userform Issue. Results are incorrect

    Instead of using:

    Please Login or Register  to view this content.
    limit the range like this:

    Please Login or Register  to view this content.
    for example.

+ 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. UserForm to search a list and display results
    By Kealy in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-26-2018, 04:39 AM
  2. [SOLVED] userform. search and display results from that row
    By SPARKY347 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-15-2015, 07:40 AM
  3. [SOLVED] Display search results inluding results that match patrially
    By RichTea88 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-06-2013, 08:52 AM
  4. Search through database and display results in userform
    By karthikcoep in forum Excel Programming / VBA / Macros
    Replies: 20
    Last Post: 05-24-2012, 05:08 AM
  5. Re: Search through database and display results in userform
    By sacarnold in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 12-12-2011, 01:37 AM
  6. Search through database and display results in userform
    By postmatt in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 01-31-2011, 10:04 AM
  7. trying to use VBA to concatenate and display search results on a userform
    By Case45 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 09-17-2009, 09:46 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