title: vb.net - Comparing two text files and retrieving a specific value
body: <p><strong>this question is related to my previous questions</strong></p>
  
  <p>I'm currently working on a Registration form where all the details of a student are save in a text file.</p>
  
  <p>I populated the combobox using a textfile.</p>
  
  <p>The format of these values are for example: (code~school name) SCH001~Saint 
  Thomas College</p>
  
  <p>this is how I saved the details in a text file:</p>
  
  <pre><code>Dim firstname, lastname, email, mobile, level, currentschool, currenttrack, institution1, institution2, institution3, institution4, institution5, institution6, courses1, courses2, courses3, macaddress, eventcode, idseq, filename, logfiledirectory, targetdirectory, log, configdir, printschool As String
      firstname = txtFName.Text
      lastname = txtLName.Text
      email = txtEmail.Text
      mobile = txtMobile.Text
      level = cmbLevel.Text
      currenttrack = cmbCurrentTrack.Text
      printschool = cmbCurrentSchool.Text
      currentschool = cmbCurrentSchool.SelectedValue
      institution1 = cmbInstitution1.SelectedValue
      institution2 = cmbInstitution2.SelectedValue
      institution3 = cmbInstitution3.SelectedValue
      institution4 = cmbInstitution4.SelectedValue
      institution5 = cmbInstitution5.SelectedValue
      institution6 = cmbInstitution6.SelectedValue
      courses1 = cmbCourse1.SelectedValue
      courses2 = cmbCourse2.SelectedValue
      courses3 = cmbCourse3.SelectedValue
  
      If mobile = "" Then
          mobile = "09000000000"
      End If
  
      If firstname = "" Or lastname = "" Or email = "" Or level = "" Or currentschool = "" Or currenttrack = "" Then
          MessageBox.Show("Please enter the required fields!", "Registration", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)
  </code></pre>
  
  <p>I have a datagridview where all the saved details in a text file are shown.
  here's a screenshot of my datagridview:
  <a href="https://i.stack.imgur.com/4T8Rp.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/4T8Rp.png" alt="enter image description here"></a></p>
  
  <p><strong>WHAT I WANT TO DO: I want to retrieve the School name using the current school code (refer to the image) from the source text file(the one I used to populated my comboboxes). Instead of the school code, I want the School name to be shown in the datagridview.</strong>
  <strong>Is there a possible way to do it?</strong></p>
  
  <p>I hope you guys understand what im trying to say.
  Im new here.</p>