Hello i was wondering if anyone could point out what i am doing wrong what i am trying to do is just print out the contents of a node i have read most of the api but i just need a little bit more help.<br><br><br><div style="margin-left: 40px;">
#include <axl.h><br> #include <stdio.h><br><br> int main (int argc, char **argv)<br> {<br> axlError **error;<br><br> // top level definitions <br> axlDoc *doc = NULL;<br> axlNode *node = NULL;<br>
const char * value;<br> <br> // initialize axl library <br> if (! axl_init ()) {<br> printf ("Unable to initialize Axl library\n");<br> return -1;<br> }<br><br> // get current doc reference
<br> doc = axl_doc_parse_from_file ("test.xml", error);<br> if (doc == NULL) {<br> axl_error_free (*error);<br> return false;<br> }<br> <br> node = axl_doc_get_root(doc);<br> value = axl_node_get_content(node, NULL);
<br> printf("%s \n", value);<br> <br> // release the document <br> axl_doc_free (doc);<br><br> // cleanup axl library <br> axl_end ();<br><br> return true;<br> }<br><br></div>Thanks<br>