XML question


#1

I’m trying to use the xmldocument and xmlelement classes. I am getting a compile error on the following…

XmlDocument theDoc(File(sFilename));
XmlElement* mainElement = theDoc.getDocumentElement();  <---- C2228: left of '.getDocumentElement' must have class/struct/union

I’ve added …

class XMLDocument;

Is there some other header/class that I’m missing?

I’ve copied this directly from the xmldocument reference.

Thanks


#2

Do it like this:


#3

Thanks Jules!