I have a code snippet :
XmlDocument doc = new XmlDocument(); try { doc.LoadXml(xmlPath); } catch (Exception ex) { string exMessage = ex.Message; }
You're passing a file path to a parameter that should contain the XML itself.