Convert AccountID to all lowercase - InfoPath Dev
in

InfoPath Dev

Convert AccountID to all lowercase

Last post 10-03-2014 12:37 PM by jawitthoft. 4 replies.
Page 1 of 1 (5 items)
Sort Posts: Previous Next
  • 10-03-2014 10:45 AM

    Convert AccountID to all lowercase

     Hi - In my form I am using the Person/Group Picker control to set an approver and in order for the approver to be able to approve the form I need to verify the AccountID from the people picker matches the CurrentUser.

    On Form Load a Rule translate the CurrentUser ID to all lowercase and I need to do the same on the AccountID field from the people picker. When I added the Rule to another field to translate the AccountID when the field is

    not blank, it doesn't work, the AccountID is still in all CAPS so the CurrentUser and AccountID don't match so the approver cannot select approve.

     Any suggestions on what I'm doing wrong?

     

    Thanks,

     

    Jennifer Witthoft

  • 10-03-2014 10:52 AM In reply to

    Re: Convert AccountID to all lowercase

    Hi - are you sure your rule is firing? Is the field that rule is on changing so the rule fires? Maybe use a default value in another field that translates the account ID to lowercase and compare to that field instead of trying to change the value for the Account ID itself?

    Hilary Stoupa

  • 10-03-2014 11:39 AM In reply to

    Re: Convert AccountID to all lowercase

     Thanks for the quick reply. What do you suggest using as a default value? Not quite sure I understand.

  • 10-03-2014 11:47 AM In reply to

    Re: Convert AccountID to all lowercase

    translate(AccountID, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz')

    So - this would be another field in your data source, outside the people picker fields. You'd set the default for this field using a formula like the one above, selecting the account id field from the people picker in the formula editor. Does that make sense? You can temporarily put the field on the form so you can verify the formula is working. Then you can compare against that field instead of the account ID.

    You could also use the translate function directly when you compare current user to account ID in your rules to determine if the user can approve, but this may be a little easier.

    Hilary Stoupa

  • 10-03-2014 12:37 PM In reply to

    Re: Convert AccountID to all lowercase

     Now I get it! Thanks! It worked by setting the default to the translate formula. I had it as a rule and didn't realize you could put formulas like that as defaults...learned something new.

     

    Thanks Hilary!

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