After saved the InfoPath form data into a document library, I reloaded it and then modified the value of a field, for example, set the value of the filed be empty. However, if I reloaded the InfoPath form data again, I found that the value of the modified field was still empty. I don't know whether the cause is related to the InfoPath cache mechanism. Has anybody any solutions to deal with this problem? I post the codes shown as following. Thanks.
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
XmlFormView1.XsnLocation = "~sitecollection/FormTemplateLibrary/SalesVisitReport.xsn"; XmlFormView1.SaveLocation = "~sitecollection/FormDataLibrary/";
}
}
//This button is used to reload the InfoPath form data from the document library
protected void btnLoad_Click(object sender, EventArgs e)
{
XmlFormView1.XsnLocation = string.Empty;
XmlFormView1.XmlLocation =
"~sitecollection/FormDataLibrary/SalesVisitReport1.xml";
}
There is no accident.