Runtime error with tinyXML element access
问题 yester day was my first attempt. I am trying to catch the variable "time" in the following "new.xml" file <?xml version="1.0" standalone=no> <main> <ToDo time="1"> <Item priority="1"> Go to the <bold>Toy store!</bold></Item> <Item priority="2"> Do bills</Item> </ToDo> <ToDo time="2"> <Item priority="1"> Go to the Second<bold>Toy store!</bold></Item> </ToDo> </main> Here is my code TiXmlDocument doc("new.xml"); TiXmlNode * element=doc.FirstChild("main"); element=element->FirstChild("ToDo");