Menu

Reading a simple XML file. (Example code)

2006-03-25
2013-05-20
  • RikkiAnderzoni

    RikkiAnderzoni - 2006-03-25

    I am using my interpretation of example code found at the TinyXML site.

    http://paste.cplusplus.se/paste.php?id=3354

    That's the code I am using. I'd like to get some help with what TiXmlElement actually is and how I use it in my for-statements.

    Anything else you'd like to comment on and help out with is gladly accepted too.

     
    • B Sizer

      B Sizer - 2006-03-25

      You haven't checked the results of line 51 (or 75) in your code. Those are the obvious problem points. Your conditional is 'pElem' so if you start off with pElem equalling NULL or zero then nothing will happen. Beyond that, it's hard to say exactly what is wrong with line 51 without knowing the format of your XML file.

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.