Reducing selection in a dropdown List box - InfoPath Dev
in

InfoPath Dev

Reducing selection in a dropdown List box

Last post 11-30-2015 07:36 AM by Hilary Stoupa. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 11-11-2015 07:32 AM

    Reducing selection in a dropdown List box

    Hello,

    I was wondering if its possible to remove or hide an item from a list box once a giving item has been selected within a repeating table?

    I have 1 dropdown list box which holds 6 line items.. When the user selects item 1, and then adds a new line using the repeating table option. I then don't want the item which has already been inserted to NOT appear in the listbox for the new line. 

    I've watched a S.Y.M Wong-A-Ton do this on YouTube, but he uses two list boxes or comboxes, I can just about get my head around how he does it but, I only have 1 listbox,  so I have nothing to reference or check against apart from the previous line selection.

     Any help will be mush appreciated.

    Thanks

    Mike 

     

  • 11-13-2015 10:19 AM In reply to

    Re: Reducing selection in a dropdown List box

     I've attached a sample - save it locally, right click on the saved file and select design to open in design mode. There is a filter on the dropdown. Preview and you can see how the entries disappear from the list after selection. :)

    Hilary Stoupa

  • 11-26-2015 05:38 AM In reply to

    Re: Reducing selection in a dropdown List box

    Hello Hilary, and thank you! Your sample shows exactly what I'm looking for. Perfectly.

    I'll have a little play around on my form, but I'm really not sure now how do I get this string into my listbox?

    Your expression: 

    /nutrition/food/name[not(. = xdXDocument:get-DOM()/my:myFields/my:group1/my:group2/my:field1)]

    My Expression: 

    /dfs:myFields/dfs:dataFields/d:SharePointListItem_RW/d:Harard_x0020_Type[not(. = xdXDocument:get-DOM()//my:myFields/my:gRiskAssessment/my:group24/my:group25/my:cmbMainSelect 

    How do you create "Expressions"? I'm only use to using standard, click rule things,,,

    Thanks again Hilary,

    Mike 

     

    UP-Date 

    Sorry Hilary.. I've managed to do it :-) It works a treat - Very happy.

    I would like to know though, Is there an easy way to do expressions - Seem to have more options when using expression statements. I'll do some google'in..

    Many Thanks

    Mike 


  • 11-30-2015 07:36 AM In reply to

    Re: Reducing selection in a dropdown List box

    Glad you found it - this is just a standard XPath expression, so that is what to focus on - the better you understand XPath, the easier this gets. :)
    Hilary Stoupa

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