title: adding data from text file to listbox
body: <p>i am having problems with loading in data from a text file (notepad txt file) and displaying it in a listbox. the following is my code, not sure why it doesn't load the data</p>
  
  <pre><code>private void loadData() {
          try {
              using (StreamReader reader = new StreamReader("visits.txt"))     //Reads in file
              {
                  string line;
                  while ((line = reader.ReadLine()) != null) {
                      string[] data = line.Split(',');               //Splits the lines up when there is a ,
                      lstDeliveries.Items.Add(data[0] + ", " + data[1] + ", " + data[2]);
                      lstPickups.Items.Add(data[3] + ", " + data[4]);                                              
                  }
              }
          }
          catch (FileNotFoundException) {
              MessageBox.Show("The file was not found!!");      //Provides error if file not found
              Environment.Exit(0);                        //Closes application 
          }
      }        
  </code></pre>