Guest User

Untitled

a guest
May 23rd, 2018
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 1.76 KB | None | 0 0
  1.  private void comboBox6_SelectedIndexChanged(object sender, EventArgs e)
  2.         {
  3.             comboBox7.Items.Clear();
  4.             if (System.IO.File.Exists("horariosatencion.xml"))
  5.             {
  6.                 XmlReader reader = XmlReader.Create("horariosatencion.xml");
  7.                 while (reader.Read())
  8.                 {
  9.                     if (string.Compare(reader.Name, "rutmedico") == 0)
  10.                     {
  11.                         reader.Read();
  12.  
  13.                         if (string.Compare(reader.Value, comboBox5.SelectedItem.ToString()) == 0)
  14.                         {
  15.                             reader.Read();
  16.                             reader.Read();
  17.                             if (string.Compare(reader.Name, "fecha") == 0)
  18.                             {
  19.                                 reader.Read();
  20.                                 if (string.Compare(reader.Value, comboBox6.SelectedItem.ToString()) == 0)
  21.                                 {
  22.                                     reader.Read();
  23.                                     reader.Read();
  24.  
  25.                                     while (reader.Read())
  26.                                     {
  27.                                         if (string.Compare(reader.Name, "hora") == 0)
  28.                                         {
  29.                                             reader.Read();
  30.                                             comboBox7.Items.Add(reader.Value);
  31.                                             reader.Read();
  32.                                         }
  33.                                     }
  34.                                 }
  35.  
  36.                             }
  37.                         }
  38.  
  39.  
  40.                     }
  41.                 }
  42.                 reader.Close();
  43.             }
  44.         }
Add Comment
Please, Sign In to add comment