Reading XML tags from file

Hello everyone,

I am trying to extract the values of various tags in an XML file. I tried following the example with ofxXmlSettings but I am still having problems. Here is my hacked together code.

  
void testApp::setup(){  
    ofBackground(255, 255, 255);  
  
    if( XML.loadFile("index.xml") ){  
        printf("File Loaded Sucessfully \n\n");  
        }  
    else{  
        printf("File Failed To Load");  
        }  
  
  
    int numOfTags = XML.getNumTags("wx_station_index:station_id");  
    XML.pushTag("wx_station_index", numOfTags-1);  
  
    if(numOfTags > 0) {  
        //XML.pushTag("station", numDragTags-1);  
        //int numStationTags = XML.getNumTags("station");  
        //if(numStationTags > 0) {  
  
        int numStationTags = XML.getNumTags("station");  
  
        printf("%d\n", numOfTags);  
        printf("%d\n", numStationTags);  
        for(int i = 0; i < numStationTags; i++){  
            char stationID = XML.getValue("station_id", 0, i);  
            printf("%c\n", stationID);  
            }  
  
            }  
    else {  
    printf("Error");  
    }  
  
  
  
}  
  

And here is a part of the XML file:

  
?xml version="1.0" encoding="UTF-8"?>  
<wx_station_index>  
        <credit>NOAA's National Weather Service</credit>  
        <credit_URL>[http://weather.gov/</credit-URL>](http://weather.gov/</credit-URL>)  
        <image>  
                <url>[http://weather.gov/images/xml-logo.gif</url>](http://weather.gov/images/xml-logo.gif</url>)  
                <title>NOAA's National Weather Service</title>  
                <link>[http://weather.gov</link>](http://weather.gov</link>)  
        </image>  
        <suggested_pickup>08:00 EST</suggested_pickup>  
        <suggested_pickup_period>1140</suggested_pickup_period>  
	<station>  
		<station_id>TAPA</station_id>  
		<state>AG</state>  
            	<station_name>Vc Bird Intl Airport Antigua</station_name>  
		<latitude>17.117</latitude>  
		<longitude>-61.783</longitude>  
            	<html_url>[http://weather.noaa.gov/weather/current/TAPA.html</html-url>](http://weather.noaa.gov/weather/current/TAPA.html</html-url>)  
            	<rss_url>[http://weather.gov/xml/current-obs/TAPA.rss</rss-url>](http://weather.gov/xml/current-obs/TAPA.rss</rss-url>)  
            	<xml_url>[http://weather.gov/xml/current-obs/TAPA.xml</xml-url>](http://weather.gov/xml/current-obs/TAPA.xml</xml-url>)  
	</station>  
  
	<station>  
		<station_id>TKPN</station_id>  
		<state>AG</state>  
            	<station_name>Charlestown/Newcast</station_name>  
		<latitude>17.2</latitude>  
		<longitude>-62.583</longitude>  
            	<html_url>[http://weather.noaa.gov/weather/current/TKPN.html</html-url>](http://weather.noaa.gov/weather/current/TKPN.html</html-url>)  
            	<rss_url>[http://weather.gov/xml/current-obs/TKPN.rss</rss-url>](http://weather.gov/xml/current-obs/TKPN.rss</rss-url>)  
            	<xml_url>[http://weather.gov/xml/current-obs/TKPN.xml</xml-url>](http://weather.gov/xml/current-obs/TKPN.xml</xml-url>)  
	</station>  
  
	<station>  
		<station_id>TRPM</station_id>  
		<state>AG</state>  
            	<station_name>Blackburne/Plymouth</station_name>  
		<latitude>16.75</latitude>  
		<longitude>-62.167</longitude>  
            	<html_url>[http://weather.noaa.gov/weather/current/TRPM.html</html-url>](http://weather.noaa.gov/weather/current/TRPM.html</html-url>)  
            	<rss_url>[http://weather.gov/xml/current-obs/TRPM.rss</rss-url>](http://weather.gov/xml/current-obs/TRPM.rss</rss-url>)  
            	<xml_url>[http://weather.gov/xml/current-obs/TRPM.xml</xml-url>](http://weather.gov/xml/current-obs/TRPM.xml</xml-url>)  
	</station>  

Ultimately I would like to store the values of the tags into an array. Right now I am just trying to get the values of the tags written to the console with printf(). Right now it returns a 1 and 2556, the number of the tags. I cannot get it to display any values though.

Thanks in advance,
Shawn