Here's my scenario:
1. On form load, I added a rule to check if a SharePoint field (from the SharePoint list my form is published to) is set to a string, say "enable". The rule sets a flag in infopath (boolean field) to "true".
2. On form submit, I added a rule to set the flag to "false".
3. The fields on the form each have rules to "disable this control" when the flag is "false", i.e. after the form is initially submitted.
4. Testing this, I submit a form to SharePoint, open it up and sure enough the fields are disabled. All good there.
5. I manually change in the SharePoint item the string field to say "enable", so I would expect my rule to run and the flag updated. I open up the form again.
The fields are still disabled! The flag is still set to "false"!
What is going on here? Why doesn't this work? Either the rule is never run or the condition is failing somehow. And how to debug something like this?
I am using InfoPath 2010 which is published to a SharePoint 2010 form library.