Data Filtering and displaying corresponding data elements - InfoPath Dev
in

InfoPath Dev

Use our Google Custom Search for best site search results.

Data Filtering and displaying corresponding data elements

Last post 11-09-2011 08:05 AM by InfoPathAddict. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 10-24-2011 12:27 PM

    Data Filtering and displaying corresponding data elements

    Hi,

    I have a unique situation,  I pulled data from a table and loaded to a dropdown, but I want to show the corresponding rows other data in a label or text box.

    Table A)  id1, id1Desc, id2, id2Desc, id3, id3Desc

    I'm displaying id3Desc in a drop down, as soon as I select the dropdown, I want hte corresponding id1Desc and id2Desc in a text box or label.

  • 10-24-2011 12:37 PM In reply to

    Re: Data Filtering and displaying corresponding data elements

    Hi,

    You can use some rules into your dropdown id3Desc.

    On this rule that use Action "Set a value to a field", you can affect data two 2 InfoPath field in order to show your data.

    For exemple, select your InfoPath Field "id2Desc" in the rule and set the value by filter your secondary data source with the value select in the dropdown (for exemple : SecondaryDataSource/ID2Desc[ID3Desc = dropdownValue]).

     It is not so easy to explain like this...

    Have a look here : http://office.microsoft.com/en-us/infopath-help/filter-the-data-that-is-displayed-in-a-control-HA010024281.aspx

    Hope this help.

    RĂ©mi MATAYRON / MVP InfoPath
    Visit my blog : Infopath Blog
  • 10-25-2011 10:36 AM In reply to

    Re: Data Filtering and displaying corresponding data elements

    its not working either way.  Let me give you the steps I tried, may be there are some issues with my steps:

    1) I have repeating section for a table item

    2) It has one dropdown control which is bound to secondary Dataconnection (secondary DC is tied to a lookup table with the following column(id1, desc1, id2, desc2, id3, desc3)

    3) the display name set to the desc3 column and value field is set to ID3 field

    Now everything looks good as expected, now the requirement came to display Desc2 and Desc1

    4) Now I created a rule on the Dropdown control

    5) Action=  Set a Field's  value

    6) set the Field= Desc2

    5)@Desc2[@ID3[. = current()]]

    I repeated the same for the Desc1

     

    Now, when I preview and choose the dropdown first time it shows the expected value in Desc1 and Desc2. but when I choose another item, its not chaning the value.  it still show the first selection data.  -Any idea how to fix this?

     

  • 11-09-2011 08:05 AM In reply to

    Re: Data Filtering and displaying corresponding data elements

    its not working either way.  Let me give you the steps I tried, may be there are some issues with my steps:

    1) I have repeating section for a table item

    2) It has one dropdown control which is bound to secondary Dataconnection (secondary DC is tied to a lookup table with the following column(id1, desc1, id2, desc2, id3, desc3)

    3) the display name set to the desc3 column and value field is set to ID3 field

    Now everything looks good as expected, now the requirement came to display Desc2 and Desc1

    4) Now I created a rule on the Dropdown control

    5) Action=  Set a Field's  value

    6) set the Field= Desc2

    5)@Desc2[@ID3[. = current()]]

    I repeated the same for the Desc1

     

    Now, when I preview and choose the dropdown first time it shows the expected value in Desc1 and Desc2. but when I choose another item, its not chaning the value.  it still show the first selection data.  -Any idea how to fix this?

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