+ Reply to Thread
Results 1 to 13 of 13

Autocomplete data validation list

  1. #1
    Forum Contributor
    Join Date
    06-26-2014
    Location
    Houston
    MS-Off Ver
    365
    Posts
    196

    Autocomplete data validation list

    I'm trying to allow autocomplete on a data validation list instead of having to scroll through all choices. I found you can create a combo box and add code, but I am getting an error when I click anywhere on the sheet. Compile Error: Ambiguous name detected: Worksheet_SelectionChange

    I have a combo box added, which I names TempCombo as it instructed.

    This is the code I used. Any ideas?


    Please Login or Register  to view this content.

  2. #2
    Forum Contributor
    Join Date
    06-26-2014
    Location
    Houston
    MS-Off Ver
    365
    Posts
    196

    Re: Autocomplete data validation list

    Or does anyone have a different way to achieve autocomplete in the data validation list?

  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: Autocomplete data validation list

    Hi DW

    This error message would seem to indicate you have two procedures with the same name.

    Compile Error: Ambiguous name detected
    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.

  4. #4
    Forum Contributor
    Join Date
    06-26-2014
    Location
    Houston
    MS-Off Ver
    365
    Posts
    196

    Re: Autocomplete data validation list

    Hm, It looks like I do. Do you know if I would have to have this code on the specific sheet that contains the data validation boxes, or could it be on a module?

  5. #5
    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: Autocomplete data validation list

    Hi DW

    The real question is why do you have two procedures with the same Name? And, what are they doing? Procedures can be made to Multi-task...

  6. #6
    Forum Contributor
    Join Date
    06-26-2014
    Location
    Houston
    MS-Off Ver
    365
    Posts
    196

    Re: Autocomplete data validation list

    The existing one is to allow me to click on a cell and trigger a copy of the info from the next couple of columns to the right, and paste down to the end of the current data on the sheet. Can you not Worksheet_SelectionChange on a sheet twice?

    Here is the existing:

    Please Login or Register  to view this content.


    Thanks!

  7. #7
    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: Autocomplete data validation list

    Hi DW

    No you cannot...
    Can you not Worksheet_SelectionChange on a sheet twice?
    But...they can be combined...probably something like this (not tested)...
    Please Login or Register  to view this content.
    Last edited by jaslake; 03-15-2017 at 03:30 PM.

  8. #8
    Forum Contributor
    Join Date
    06-26-2014
    Location
    Houston
    MS-Off Ver
    365
    Posts
    196

    Re: Autocomplete data validation list

    Hm. not seeming to work. So what you are suggesting is to use this code in total replacement of the original code I have, to combine both the original functionality and to add the data validation autocomplete?

  9. #9
    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: Autocomplete data validation list

    Hi DW

    Yes...replace this Code in totality...Private Sub Worksheet_SelectionChange(ByVal Target As Range)
    So what you are suggesting is to use this code in total replacement of the original code I have, to combine both the original functionality and to add the data validation autocomplete?
    As I indicated...not tested...if you wish tested Code...

    Please attach a sample workbook the Structure of which is the same as your actual workbook.

    Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    INCLUDE ANY CODE YOU'RE USING OR HAVE TRIED.

    Remember to desensitize the data.

    To do this, click on Go Advanced (below the Edit Window) while you are composing a reply, then scroll down to and click on Manage Attachments and the Upload window will open. Click on Browse and navigate to (and double-click) the file icon that you want to attach, then click on Upload and Close this Window to return to the Edit window. When you have finished composing your post, click on Submit Post.

  10. #10
    Forum Contributor
    Join Date
    06-26-2014
    Location
    Houston
    MS-Off Ver
    365
    Posts
    196

    Re: Autocomplete data validation list

    Alright, here we go.

    I attached our dumbed down sheets.

    The Product Order Autocomplete Test workbook is basically an order form, someone calls in some orders, then we enter them on this log and send it out daily. When the order comes in, we go to the Master table at the top of the Orders sheet, and click in the dropdown boxes in D12:D14 depending on which store calls in, to choose the product to add to the order list for the day. The data validation lists are on the Product List sheet. The Location # column, E, updates via vlookup from the Master Product Sheet. After the correct Store and Product have been chosen, we click the corresponding blue cell for the product we need to add, and it pastes down below under the last table, which we start a new one each day.

    The Add Row to Master Table button is just to add a new row to that Master sheet, as just copying and pasting or inserting rows does not keep the one click copy / paste function working.

    The second sheet I attached, DEAL SHEET-DRAFT AutoComplete - Test, has the functioning data validation autocomplete. I highlighted some of the fields that you can double click and pop open the box and start typing.

    The goal is just to get Product Order Autocomplete Test workbook to have a functioning autocomplete for the data validation cells.


    Just let me know if this babbling makes any sense.


    Thanks!

  11. #11
    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: Autocomplete data validation list

    Hi DW

    I'll be tied up all day tomorrow...traveling for most of the day...will get back to this tomorrow evening or Friday.

  12. #12
    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: Autocomplete data validation list

    Hi dw

    The Code in the attached appears to do this...
    The goal is just to get Product Order Autocomplete Test workbook to have a functioning autocomplete for the data validation cells.
    I have a suspicion you're wanting to do more but I'm unable to discern what that is.
    Attached Files Attached Files

  13. #13
    Forum Contributor
    Join Date
    06-26-2014
    Location
    Houston
    MS-Off Ver
    365
    Posts
    196

    Re: Autocomplete data validation list

    Hm, When I click on one of the data validation boxes, a drop down box appears, but the choices are blank, and when I start typing, nothing populates. For example, on the Orders sheet, I would like to be able to type in C12 and have Best Buy, Radio Shack or Target come up as I am typing, but it does not populate anything as I am typing. I have attached a screenshot of what happens when I click on it.

    Thanks!
    Attached Images Attached Images

+ 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. Autocomplete Data Validation Drop Down
    By bgrish3 in forum Excel General
    Replies: 3
    Last Post: 02-22-2017, 09:58 AM
  2. [SOLVED] Can a Data Validation do an autocomplete?
    By taylorsm in forum Excel General
    Replies: 11
    Last Post: 11-03-2016, 07:11 PM
  3. [SOLVED] Data Validation + ComboBox Autocomplete
    By kiwi_harry in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 12-16-2014, 10:15 PM
  4. [SOLVED] Autocomplete dropdown list, NOT data validation or ActiveX
    By Phillips Contracting in forum Excel General
    Replies: 7
    Last Post: 03-24-2014, 02:31 PM
  5. Data Validation Autocomplete
    By jrocchio in forum Excel General
    Replies: 4
    Last Post: 04-16-2013, 12:08 PM
  6. Autocomplete Date Validation List drop-down
    By adds007 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-16-2011, 02:06 PM
  7. Validation List Autocomplete
    By Guilherme Loretti in forum Excel General
    Replies: 2
    Last Post: 03-21-2006, 09:15 PM

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