title: C# The network path was not found (Login)
body: <p>So after switching to a different PC using sourcetree and github, one of the 2 login functions stopped working. When I'm logging in as a customer it works fine, but when I try to login as a employee it doesn't load and gives me the error "The network patch was not found"</p>
  
  <p>At the desktop pc it worked fine, now I switched to my laptop and it stopped working all of a sudden. But the strange part is that one of the 2 logins still works.</p>
  
  <pre><code>        {
              string databasestring = "Data Source=DESKTOP-LCG9HIA;Initial Catalog=Klantenportaal;Integrated Security=True";
              //string databasestring = "Data Source=DESKTOP-UPPSPIA;Initial Catalog=Klantenportaal;Integrated Security=True";
              SqlConnection con = new SqlConnection();
              try
              {
                  if (rbKlant.Checked == true)
                  {
                      con.ConnectionString = databasestring;
                      con.Open();
                      SqlCommand cmd = new SqlCommand("SELECT klant_id, username, wachtwoord, rol FROM Klant WHERE username = @username and wachtwoord = @wachtwoord", con);
  
                      cmd.Parameters.Add(new SqlParameter("@username", tbUsername.Text));
                      cmd.Parameters.Add(new SqlParameter("@wachtwoord", tbPassword.Text));
                      SqlDataReader dr = cmd.ExecuteReader();
  
                      if (dr.Read())
                      {
                          Session["Username"] = tbUsername.Text;
                          Session["UserID"] = dr[0].ToString();
                          con.Close();
                          dr.Close();
                          Response.Redirect("Dashboard.aspx");
                      }
                      else
                      {
                          lblError.Text = "Gebruikersnaam en/of wachtwoord niet correct ingevoerd, probeer opnieuw";
                          dr.Close();
                      }
                  }
  
                  else if (rbMedewerker.Checked == true)
                  {
                      con.ConnectionString = databasestring;
                      con.Open();
                      SqlCommand cmd = new SqlCommand("SELECT medewerker_id, username, wachtwoord, rol FROM Medewerker WHERE username = @username and wachtwoord = @wachtwoord", con);
  
                      cmd.Parameters.Add(new SqlParameter("@username", tbUsername.Text));
                      cmd.Parameters.Add(new SqlParameter("@wachtwoord", tbPassword.Text));
                      SqlDataReader dr = cmd.ExecuteReader();
  
                      if (dr.Read())
                      {
                          Session["Username"] = tbUsername.Text;
                          Session["MedewerkerID"] = dr[0].ToString();
                          con.Close();
                          dr.Close();
                          Response.Redirect("MedDashboard.aspx");
                      }
                      else
                      {
                          lblError.Text = "Gebruikersnaam en/of wachtwoord niet correct ingevoerd, probeer opnieuw";
                          dr.Close();
                      }
                  }
  
                  else
                  {
                      lblError.Text = "Geen keuze gemaakt tussen klant of medewerker";
                  }
  
              }
              catch 
              {
                  lblError.Text = "Onbekende fout, probeer het later nog eens";
              }
  
              finally
              {
                  if (con.State == System.Data.ConnectionState.Open)
                      con.Close();
                      con.Dispose();
              }```
  
  So the login customer ("klant") actually redirects me correct, while the login for employee("medewerker") isn't fucntioning anymore.
  </code></pre>