How can I create a drop-down list box for each row in a repeating table? - InfoPath Dev
in

InfoPath Dev

Use our Google Custom Search for best site search results.

How can I create a drop-down list box for each row in a repeating table?

Last post 02-02-2010 12:17 PM by geoffgarcia. 8 replies.
Page 1 of 1 (9 items)
Sort Posts: Previous Next
  • 01-22-2010 03:29 PM

    How can I create a drop-down list box for each row in a repeating table?

    I'm creating an "order form" that displays an inventory list from an Access db.  The goal is to have a user then change a "quantity" field to the right of each inventory item, to reflect how many of the item they want to order.
    To get the data to appear in the form I've attached the db and created a "Repeating Table" that includes some basic fields like: ID, Name, Description, Price, etc.

    What I'm stuck on is how to add a drop-down to the right side of each of these inventory items, where users can select the quantity of how many of that item they'd like to order.

    I've tried adding field elements and attributes, that repeat and don't, and no matter what I try when I preview the form if I change a drop-down on one of the rows it changes on all of the rows.  I'm a complete noob when it comes to infopath.

    Any advice on how I can do this?

     

    Attach is my db and form in case anyone wants to take a look at what I'm trying to do here.

  • 01-28-2010 12:53 PM In reply to

    Re: How can I create a drop-down list box in a repeating table?

     anyone have any advice? I'm still stuck on this :(

  • 01-28-2010 06:19 PM In reply to

    Re: How can I create a drop-down list box in a repeating table?

     Can you attach a screenshot of your data source, indicating to which field the dropdown box is bound?

    Jimmy Rishe / Software Developer / Microsoft MVP
    Qdabra Software
  • 01-29-2010 08:57 AM In reply to

    Re: How can I create a drop-down list box in a repeating table?

    Jimmy:

     Can you attach a screenshot of your data source, indicating to which field the dropdown box is bound?

     

    Attached is the datasource (Main) which shows the binding to the dropdown.


  • 01-29-2010 08:58 AM In reply to

    Re: How can I create a drop-down list box in a repeating table?

    Jimmy:

     Can you attach a screenshot of your data source, indicating to which field the dropdown box is bound?

    Attached is the data source from the Access DB pulling the inventory data


  • 01-29-2010 07:56 PM In reply to

    Re: How can I create a drop-down list box in a repeating table?

     The problem is that your Quantity field is in a completely separate place from the rest of your fields.  In order for it to be of any use, it needs to be part of the same repeating data as the other fields in the table (like ItemName, Description, and Price are).  I don't know if that's an option in your case, but that's what's necessary.

    Jimmy Rishe / Software Developer / Microsoft MVP
    Qdabra Software
  • 02-01-2010 11:38 AM In reply to

    Re: How can I create a drop-down list box in a repeating table?

    Thanks for giving me some direction here.

    I created another table within my database.  When I go into my dataconnection and attempt to add the new table to the existing db datasource it prompts me to add a relationship, however there isn't one. If I fudge a relationship, it goes through and adds the table to the datasource (but this seems fishy).

    The next minor issue I run into is trying to set the values of the drop-down list.  After I've added the control and go to it's properties, if I select

    • Enter List Box Entries Manually - It prompts me to set a default, however the "Set Default" button is always grayed out no matter what I do.
    • Look up values in the form's data source - it points to the main data source, as opposed to my secondary database attached one
    • Look up values from an external data source - Here I can select my data source, however when I navigate to the quantity table and the column I have the data in I get prompted with this error "You selected the field where the control saves data.  Instead, select the field where the control looks up data".
    I feel helpless with this stuff!

     



  • 02-02-2010 05:37 AM In reply to

    Re: How can I create a drop-down list box in a repeating table?

     The Set Default button should allow you to indicate one of the list box entries to mark it as the default.  Have you tried entering any items?

    The other two options are for indicating a place where the list of options is stored, not where the control's value will be stored.  If the list of options you want to provide is fixed, you can just use the "Enter List Box Entries Manually" option.

    Jimmy Rishe / Software Developer / Microsoft MVP
    Qdabra Software
  • 02-02-2010 12:17 PM In reply to

    Re: How can I create a drop-down list box in a repeating table?

    Jimmy:

     The Set Default button should allow you to indicate one of the list box entries to mark it as the default.  Have you tried entering any items?

    The other two options are for indicating a place where the list of options is stored, not where the control's value will be stored.  If the list of options you want to provide is fixed, you can just use the "Enter List Box Entries Manually" option.

    For whatever reason the program doesn't let me create a default item and doesn't let me save because of it.  I've tried entering data several times and opening and closing the program. Nothing seems to work. The set default button is always grayed out.
Page 1 of 1 (9 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.