0
votes

I am working with Infopath forms and workflows. 1) I have added a new field to the existing Data Source in Existing Infopath Template. But I have not added a User control from the added field. 2) I published the form with the new fields and promoted the fields as well to the library. 3) When I try to access the Field in a existing form using a event reciever(Used Xpath to access the new Field). It gives a Object Reference Exception.

How can I update the existing forms with the added new field.

Thanks in advance!

1
Is the event receiver using custom code that you wrote, or is it some sort of configurable component? If it's your own code, you should check whether the returned node is null when you try to retrieve it. Existing forms won't have the added field until they are opened and resubmitted.JLRishe
Yes Thanks for your reply. You are correct. Existing forms won't have the added field until they resubmitted. Since I am accessing the nodes through the code what I done was checked the element is available when the time of updating and if the node is not there I have created the nodes by code. Hope it will solve my problem. Thanks.SPKan

1 Answers

0
votes

Existing forms won't have the added field until they resubmitted. Since I was accessing the nodes through the code what I have done was checked the element is available when the time of updating and if the node is not there I have created the nodes by code. This worked for me.