Hello,
I am working with xml and c# and I ge this error: The data at the root level is invalid, when I try to read the xml document. Here is the code that I am working with:
public static Response Message(string doc)
{
StringReader reader = new StringReader(doc);
XmlTextReader textReader = new XmlTextReader(reader);
XmlDocument xmlDoc = new XmlDocument();
xmlDoc.Load(textReader); //gets stuck here
return Response.Message(xmlDoc);
}
Any ideas on what this problem could be would be great.
Thanks in advance