Skip to main content
Hi all,

I already read the topics about setting the Folio programmatically.

I use just this simple line of code in the Infopath Initialize Event (may be thats is a problem) to test setting the Folio to the Initiator name which is entered into a textbox in my Infopath form from the requestor.
By the way my form is published to a webserver


.Value.ToString(),"/my:myFields/my:tbInitiator");
}


I can submit my form but then in the Workspace the status of the Process Instance is Error. It says: XPath : "/my:myFields/my:tbInitiator" could not be resolved on this document.

Any help ?

Thx
I've tested something similar on my side and it works like a charm. I think your xPath might be wrong, the xPath I specified did not have the first "/", i.e.
K2.ProcessInstance.XmlFields("K2InfoPathSchema").Value,"my:myFields/my:FirstName")


You can also use the Data Manipulation event to get the correct xPath for the node that you want. Just add a Data Manipulation event, complete the wizard using required node as the source field and view the code generated.
Thanks a bomb.
Just works!

Reply