Hi All,
I hace published my browser enable infopath form in Sharepoint.
I have unchecked the Read only checkbox also.
Now i am using folloing javascript code onclick of button which is in Asp.net page to open infopath form published in Sharepoint.
1. var oApp = new ActiveXObject("InfoPath.Application");2. var oXDocumentCollection = oApp.XDocuments;
3. var oXDocument = oXDocumentCollection.Open(http://SharepointSite/Infosite/Form.xsn);
But the while debugging it gives the error "
InfoPath: InfoPath cannot open the following file:"http://localhost/Infosite/Form.xsn" The form is marked as read-only"
The open Method takes two parameter as mentioned below.
oXDocumentCollection.Open(URL,dwbehavior)
If I give dwbehavior value as "8" it gives following error.
"InfoPath: InfoPath cannot open the following file: http://sharepointsite.com/InfopathTest/Forms/AllItems.aspx.
The file is not a valid XML file.
??
The form contains XML that cannot be parsed:
A name was started with an invalid character."
Please Let me know if anyone know about the error.
Some time if i change the path it does not give Read only error.but it gives following Error
"InfoPath: InfoPath cannot open the following file: http://sharepointsite.com/InfopathTest/Forms/AllItems.aspx.
The file is not a valid XML file.
??
The form contains XML that cannot be parsed:
A name was started with an invalid character."