By the way the update call is unecessary:
Documents doc = b1.Company.GetBusinessObject(BoObjectTypes.oOrders); | |
doc.GetByKey(1); |
b1.Company.XMLAsString = true; | |
b1.Company.XmlExportType = BoXmlExportTypes.xet_ExportImportMode; | |
string xml = doc.GetAsXML(); |
xml = xml.Replace("<U_test>123</U_test>", "<U_test></U_test>"); |
int result= doc.UpdateFromXML(xml); |
int result = doc.Update(); | |
if(result!=0) | |
throw new Exception(b1.Company.GetLastErrorDescription()); |