I'm having a problem with the Person Picker control in InfoPath 2010. I enter a name and it is resolved and displayed on the control. So far, so good. Now I'm trying to retrieve the value of AccountId provided by the control. It works when I preview the form locally but when I publish it to SharePoint (this is a browser-enabled form) the AccountId is coming back as blank.
Below is the XPath I'm using. (I tried adding an index, as in "Person[1]", but InfoPath didn't like that either. Besides, I've limited the control so that only 1 user can be entered.)
/my:myFields/my:ApproverGroup/my:Analyst/pc:Person/pc:AccountId
Same result if I try to get DisplayName or AccountType--works in preview but not when I publish. And I'm publishing to my local SharePoint Server (same machine I'm developing on).
Any ideas? Thanks in advance.