Data filter - InfoPath Dev
in

InfoPath Dev

Data filter

Last post 04-04-2008 02:37 AM by ben.oates. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 04-03-2008 08:43 AM

    Data filter

    Hi all,

     I'm struggling a bit with a data filter for displaying items in a drop-down list.

    I have a repeating field called "Hardware" as you can see in the middle of the following XPath:

    /my:myFields/my:Hardware/my:HType

    HType and HVersion are non-repeating elements in my:Hardware.

    I have a data connection to a Sharepoint list and I want the drop down list for HVersion to only show version numbers where @Name (on the list) is equal to HType. I did this:

    ../@Name = xdXDocument:get-DOM()/my:myFields/my:Hardware/my:HType

    What this gives me is a filtered list of all the version numbers for the HType children of every Hardware. I just want the HType child in the same Hardware entry as the HVersion I'm currently looking at. Can anyone help me to adhust my code? Is it possible? I have tried ../my:HType and just my:HType but these do not work.

    Thanks all.

  • 04-03-2008 09:03 AM In reply to

    Hey Ben.

    I am not sure I compeletly understand what you are looking for.

    You can use a filter to show all HWversion where HWType = a field or constant.

    I think you are trying to display it. If this is in a repeating tabel or section you may be looking for the current() function to refer to the current record and not the very first record.  Seach on current to find out more on this.

  • 04-04-2008 02:37 AM In reply to

    Thanks Clay... that's brilliant.

     If anyone else has this problem, the best tutorial I found is here:

    http://blogs.msdn.com/timpash/archive/2005/10/26/Using-Current-Function.aspx

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