title: Displaying XML Data Entries With the Same Node Value
body: <p>ok first off i am fully aware of this question" <a href="https://stackoverflow.com/questions/1672750/c-sharp-showing-multiple-xml-data-entires-with-the-same-node-value">Showing Multiple XML Data Entries With the Same Node Value</a> " but it doesn't answer my question</p>
  
  <p>ok so to start off this is my xml </p>
  
  <pre><code>&lt;xml_api_reply version="1"&gt;
    &lt;weather module_id="0" tab_id="0" mobile_row="0" mobile_zipped="1" row="0" section="0"&gt;
    &lt;forecast_conditions&gt;
      &lt;day_of_week data="Wed"/&gt;
      &lt;low data="57"/&gt;
      &lt;high data="68"/&gt;
      &lt;icon data="/ig/images/weather/partly_cloudy.gif"/&gt;
      &lt;condition data="Partly Cloudy"/&gt;
    &lt;/forecast_conditions&gt;
      &lt;forecast_conditions&gt;
        &lt;day_of_week data="Thu"/&gt;
        &lt;low data="57"/&gt;
        &lt;high data="68"/&gt;
        &lt;icon data="/ig/images/weather/chance_of_rain.gif"/&gt;
        &lt;condition data="Chance of Rain"/&gt;
      &lt;/forecast_conditions&gt;
      &lt;forecast_conditions&gt;
        &lt;day_of_week data="Fri"/&gt;
        &lt;low data="59"/&gt;
        &lt;high data="68"/&gt;
        &lt;icon data="/ig/images/weather/cloudy.gif"/&gt;
        &lt;condition data="Cloudy"/&gt;
      &lt;/forecast_conditions&gt;
      &lt;forecast_conditions&gt;
        &lt;day_of_week data="Sat"/&gt;
        &lt;low data="59"/&gt;
        &lt;high data="68"/&gt;
        &lt;icon data="/ig/images/weather/cloudy.gif"/&gt;
        &lt;condition data="Cloudy"/&gt;
      &lt;/forecast_conditions&gt;
    &lt;/weather&gt;
  &lt;/xml_api_reply&gt;
  </code></pre>
  
  <p>and as you can see there are multiple <code>forecast_conditions</code> and what im wanting to do is display each day in its own string like so...</p>
  
  <pre><code>string day1;
  string day2;
  string day3;
  string day4;
  
  day1 = "Wed";
  day2 = "Thu";
  day3 = "Fri";
  day4 = "Sat";
  </code></pre>
  
  <p>but since all the heading nodes are the same ( <code>forecast_conditions</code> ) im a bit confused on how to do this</p>
  
  <p>This is how im geting it so far </p>
  
  <pre><code>foreach (XmlNode node in xmlConditions.SelectNodes("/xml_api_reply/weather/forecast_conditions"))
  {
      Conditions condition = new Conditions();
      condition.City = xmlConditions.SelectSingleNode("/xml_api_reply/weather/forecast_information/city").Attributes["data"].InnerText;
      condition.Condition = node.SelectSingleNode("condition").Attributes["data"].InnerText;
      condition.High = node.SelectSingleNode("high").Attributes["data"].InnerText;
      condition.Low = node.SelectSingleNode("low").Attributes["data"].InnerText;
      condition.DayOfWeek = node.SelectSingleNode("day_of_week").Attributes["data"].InnerText;
      conditions.Add(condition);
  }
  </code></pre>
  
  <p>and this</p>
  
  <pre><code>public class Conditions
  {
      public string DayOfWeek
      {
          get { return dayOfWeek; }
          set { dayOfWeek = value; }
      }
  </code></pre>
  
  <p>and so on</p>