以下行的代码片段是更新的InfoPath XML记录(文件)
SPWeb = _Web SPContext.Current.Web; SPList _list = _web.Lists[“SampleFormLib”];
MemoryStream的myInStream =新的MemoryStream(item.File.OpenBinary()); XmlTextReader的读者= XmlTextReader的新(myInStream);
XmlDocument的DOC =新的XmlDocument(); doc.Load(阅读器);
reader.Close(); myInStream.Close();
XmlNamespaceManager的nameSpaceManager =新的XmlNamespaceManager(doc.NameTable); nameSpaceManager.AddNamespace(“我”, “銈://schemas.microsoft.com/office/infopath/2003/myXSD/2009-06-11T12:44:57“);
doc.DocumentElement.SelectSingleNode(“我:状态”, nameSpaceManager).内部文本= “保存”; […]