Microsoft Visual Web Developer 2010 c#, il valore non è impostato a nullo.
protected void Page_Load(object sender, EventArgs e)
{
CarrelloPowerEngineService ImpCarrello = new CarrelloPowerEngineService();
XmlDocument xmlDoc = new XmlDocument();
xmlDoc.Load(HttpContext.Current.Server.MapPath(".") + "\\Prova1.XML");
StringBuilder rawXml = new StringBuilder();
rawXml.Append(GetXmlString(xmlDoc));
int result=ImpCarrello.importBasket(rawXml.ToString());
Response.Write(result);
}
static string GetXmlString(XmlDocument xmlDoc)
{
StringWriter sw = new StringWriter();
XmlTextWriter xw = new XmlTextWriter(sw);
xmlDoc.WriteTo(xw);
return sw.ToString();
}