Content check - InfoPath Dev
in

InfoPath Dev

Use our Google Custom Search for best site search results.

Content check

Last post 08-06-2008 02:10 AM by ben.oates. 4 replies.
Page 1 of 1 (5 items)
Sort Posts: Previous Next
  • 08-05-2008 04:21 AM

    Content check

    Hi,

    I have a number of buttons on my various views that I need to perform certain checks before the user can progress.

    I have managed to work out all but one of the actions for this.

    I have two repeating groups with non-repeating contents. I want my button to check that a certain field is not blank in every instance of the repeating group as at the moment it seems to pass the "SVersion is not blank" test if any instance of SVersion has data in it rather than all.

     What kind of XPath query can I use to check this please? I wouldn't even know what to start searching for!

    Thanks,

    Ben

  • 08-05-2008 04:59 AM In reply to

    Can you check this link, Hope it will helps

    http://www.infopathdev.com/forums/p/8291/30041.aspx#30041

  • 08-05-2008 05:38 AM In reply to

    Thanks for your quick response, but I am already running rules as suggested in that link and this doesn't actually give me the XPath command I need.

    I need a command that makes sure all instances of /my:Hardware/my:Version are not blank when my:Hardware is repeating.

    If you use the condition "my:Version is not blank" it will return true if any are filled in rather than all of them. I only want it to be true if every my:Version is completed.

    Any suggestions?

  • 08-05-2008 11:21 AM In reply to

    Actually, when I tried this, using the condition my:Version is not blank (an equivalent -- non-repeating field inside repeating group) it ran the action only if all the fields were filled in. I'm surprised you are getting different results.

    One way I check conditions is to add a field to my main data source (inside the very top group, in this case) and set its default value to the condition I'm checking, place the field on the form and preview the form to see when the value changes from true to false or the reverse.

     Edit:  I just realized, I tested using "is blank" so if any were blank, I had a true result. I'm trying to think of a way you'd be able to switch your condition -- maybe have a rule with a condition of my:Version is blank that sets another field's value to true and then a rule triggered off that field being true? A little kludgy, but a thought...

    Hilary Stoupa

  • 08-06-2008 02:10 AM In reply to

    I have an expression box on the form with the following formula:

    my:Users/my:UNetID != ""

    It turns to true as soon as any of the fields bound to UNetID have something in them. I should point out that my button and expression box are both outside the repeating group in case that makes a difference.

    When the expression box displays my:Users/my:UNetID it will only show the first UNetID in the repeating Users group.

    I'm going to go look into eval() but if anyone has any suggestions they would be appreciated.

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