I am new to InfoPath and I'm trying to change the views of my form based on a status value coming from a SP2010 list. I have published a form to a SP2010 list which has additional fields that can be updated in SP. The SP field "PR Status" is a choice field with "Open", "In Process", and "Closed" as the only values. When the form is first submitted by the user the default value is set to "Open". When the admin reviews the form and validates it he sets the status to either "In Process" or "Closed". Here is where the problem begins.
If the PR status is set to either open or closed I want to have the form, when re-opened, to switch to a Read Only view that I have setup. Here is what I've done:
1 - setup a retrieve data connection to get the PR Status field
2 - added form open rule to a) retrieve the PR Status field and set a form field called "current_status" to be equal to PR Status.
3 - a condition is set that if the PR Status is In Process or Closed, display the read only form.
The problem is that the field always read "In Process" not matter that the SP record is set to "Open" or "Closed". I am then unable to change to the correct view.
HELP !!! what am I missing?