Results 1 to 4 of 4
  1. #1
    Eljefegeneo is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Jan 2012
    Posts
    14

    Importing from excel into a multi-select list box

    Using Access 201 (and Excel 2010)



    I am trying to convert an old DOS based DB into Access and I can't figure out how to import data into a multi-select list box. Every time I try something it just add another field of choice. that is if I want to import A , B and C into the field, it allows me to do this, but creates a new entry int he list as A, B, C. i want it to check the boxes for A, B and C. What I need to know is how to set up the data in the Excel spreadsheet and how to import into the table field that is the multi-select list box.

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,626
    I don't understand what you mean by importing into a list box. You want to create a listbox RowSource sql based on data from Excel? Have you linked to Excel spreadsheet? Or did you import into a table? Show the RowSource sql statement.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    Eljefegeneo is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Jan 2012
    Posts
    14
    What I have is an Excel spreadsheet which has the data from an old DOS (DATAEASE) DB. Two of the fields in the old DB had what I call multiple entries. For example, in the old DB, the field was just a text field in which one could enter as much data as permitted. In this case it was countries of the world. Now I want to make that same field in Access a multi-choice field, that is, allow the entry of multiple choices of various countries. I tried to make the cell in Excel have as the data: Country A, Country B, etc. as I thought that was the way Access saw the data - the way it appears in the control when the drop-down list is not visible. But all it does it add another choice which has a check box, Country A, Country B instead of putting check marks in the selection for Country A and Country B separately. As an example, the cell in Excel shows: Australia, Austria, Germany. Can I import this data into a multi-choice field in Access where each one is a separate entry and then checked? Access already has all the selections, that is, all the appropriate countries listed. It seems to me that using a multi-choice drop down list in Access is not the easiest kind of control to use. Thanks for any help.

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,626
    What do you want to do with the data from the old fields? If you want to maintain the integrity of the data, options are:
    1. keep them as a single text string
    2. parse them out to individual records of a related child table
    3. parse them and save them as multiple values in a multi-value field
    Options 2 and 3 will require tricky VBA code.

    I don't use multi-value fields. Review http://office.microsoft.com/en-us/ac...001233722.aspx

    Multi-select control (combo or list box) can be used to save values to a multi-value field. If you want a combobox that has a RowSource of countries, need a table that has each country as a record or type the countries as a ValueList in the RowSource. How many countries are involved?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. multi select list box
    By crowegreg in forum Forms
    Replies: 1
    Last Post: 07-28-2012, 11:52 PM
  2. Replies: 5
    Last Post: 07-26-2012, 12:59 PM
  3. Multi Select List Box Trouble
    By Subwind in forum Forms
    Replies: 2
    Last Post: 06-06-2012, 04:00 AM
  4. Multi select list box
    By foxtet in forum Forms
    Replies: 1
    Last Post: 05-30-2011, 02:13 PM
  5. Replies: 1
    Last Post: 10-22-2010, 10:11 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums