"Is Not Equal To" Validation of Access Data not working - InfoPath Dev
in

InfoPath Dev

"Is Not Equal To" Validation of Access Data not working

Last post 04-04-2013 05:13 AM by Bianca. 5 replies.
Page 1 of 1 (6 items)
Sort Posts: Previous Next
  • 03-13-2013 04:24 AM

    • Bianca
    • Not Ranked
    • Joined on 03-13-2013
    • Posts 6

    "Is Not Equal To" Validation of Access Data not working

    I am building a form which is linked to an Access Database. I wish to create a text box which users will manually enter values into, and which a validation rule will then check against a field in an Access Table or Query.

    I managed this by adding a rule which has condition: field1 Is Not Equal to EQ_NAME  (where EQ_NAME is the name of the field in the access database)

    and the rule type is Validation

     However, whether I enter a value into the text field which is a valid value or not, the validation always brings up an error.

     Strangely, when trying to do it the other way round, i.e. use the "Is Equal To" rather than "Is Not Equal To" the validation works as expected. This suggests that it might be a configuration error within Infopath itself... but is there any way around this?

     

    Thanks, Bianca

  • 03-15-2013 07:47 AM In reply to

    Re: "Is Not Equal To" Validation of Access Data not working

    Hi - can you change the first drop down in your condition to "The expression" and paste the returned XPath into a reply?

    Hilary Stoupa

  • 03-28-2013 02:15 AM In reply to

    • Bianca
    • Not Ranked
    • Joined on 03-13-2013
    • Posts 6

    Re: "Is Not Equal To" Validation of Access Data not working

    Hi Hilary, thanks for your reply, sorry I have only just seen it.

    The expression is

    . != xdXDocument:GetDOM("TOTALPLANT_OM_LIMIT_SET")/dfs:myFields/dfs:dataFields/d:TOTALPLANT_OM_LIMIT_SET_Query/@EQ_NAME

     

  • 03-28-2013 06:48 AM In reply to

    Re: "Is Not Equal To" Validation of Access Data not working

    Try using EQ_NAME for the left side of the comparison (using the Select field or group... option) and with the field selection dialog still open, change the Select: dropdown to All occurrances of EQ_NAME. Then use are not equal to for the comparison and select field1 for the right side.
    Jimmy Rishe / Software Developer / Microsoft MVP
    Qdabra Software
  • 04-04-2013 05:12 AM In reply to

    • Bianca
    • Not Ranked
    • Joined on 03-13-2013
    • Posts 6

    Re: "Is Not Equal To" Validation of Access Data not working

  • 04-04-2013 05:13 AM In reply to

    • Bianca
    • Not Ranked
    • Joined on 03-13-2013
    • Posts 6

    Re: "Is Not Equal To" Validation of Access Data not working

    Hi Jimmy

     That works! Thanks, that's great :)

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