Cascading drop-downs and auto populate fields based on first two field selections.... - InfoPath Dev
in

InfoPath Dev

Use our Google Custom Search for best site search results.

Cascading drop-downs and auto populate fields based on first two field selections....

Last post 10-29-2012 02:56 PM by ErnestoM. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 10-29-2012 12:18 PM

    Cascading drop-downs and auto populate fields based on first two field selections....

    Hello - I am hoping I can get some help with this. At this point I am able to get the first two drop-down list boxes to do what I want but I am stuck at figuring out how to have field three and four auto populate based on those results. The data I have for the first two fields are in an .xml file. The first field(State) the user has to select a choice and then based that selection, only specific choices are available for the second drop-down (City), the .xml looks like this:

    <Cities>

    <City state="Washington">Redmond</City>

    <City state="Washington">Seattle</City>

    <City state="California">Los Angeles</City>

    <City state="Florida">Orlando</City>

    </Cities>

     **Now you can read the rest to explain what I need in the third and fourth field:

    here is the task which I believe can be done in infopath 2007 but am not 100% that this route will get me what I am looking for. Anyway here's the challenge...I need a  form, that will use cascading list boxes or drop-downs. First box has 5 choices to choose from, second box choices will be dependent upon the choice selected in the first box, third and fourth boxes will auto populate depending on the choices in both the first and second box(no drop-downs, just a one word result for 3rd and 4th boxes) so...if I am looking at the form, it will look something like this:

     
     
    [dropdown 1]  Select your business:(list of 5 choices to choose from(1,2,3,4,5))
    [dropdown 2]  Select an appropriate user role: (list of 3 choices depending on first choice (if the first choice is 2..... A,B,C will be the three choices to choose from, if the first choice is 5... D,E,F will be the choices...))
    ** now based on those two choices, the next two fields will auto-populate ***
    [field 3] If the first choice is 2, and the second choice is B, then the 3rd box will auto-populate with X, and the 4th field will populate with Y
     
    [field 4] If the first choice is 5, and the second choice is F, then the 3rd and 4th fields will auto-populate with P and Q
     
    My question is can this be done with Infopath 2007? The data to be used can be in an excel file, .txt file, whatever will work... Also, after looking at this, is InfoPath even the right way to go? I think it is, but if I knew for sure I wouldn't be asking for your advice/ideas...
  • 10-29-2012 02:56 PM In reply to

    Re: Cascading drop-downs and auto populate fields based on first two field selections....

    You would basically need rules, and those rules will have one specific condition each.

    So on dropdown2, when the user makes a selection, a rule will fire. Then you have various conditions:

    rule1: if dropdown1=2 AND dropdown2=B, set a field's value such that field3=X and field4=Y

    rule2: if dropdown1=5 AND dropdown2=F, set a field's value such that field3=P and field4=Q

    And so on. You can have as many rules/conditions as needed.

    It can definitely be done in InfoPath.

    Ernesto Machado
    Qdabra® Software/ InfoPathDev.com
    The InfoPath Experts – Streamline data gathering to turn process into knowledge.™


Page 1 of 1 (2 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.