title: OleDbDataReader and DataSet
body: <p>How do  i change this code to VB.NET?  So i want to use a <code>DataSet</code> instead of the <code>ADODB.Recordset</code> and an <code>OleDb.OleDbConnection</code> instead of <code>ADODB.Connection</code>. </p>
  
  <pre><code>Set oRs = New ADODB.Recordset
    oRs.Open ("Select * from Login Where Username= '" &amp; txtUsername.Text &amp; "'"),oCn,      adOpenStatic, adLockOptimistic, _
   adCmdText
  
  If txtPassword.Text &lt;&gt; oRs.Fields("Password") Then
  Call MsgBox("Incorrect Password", vbOKOnly, "Login Error")
  txtPassword.Text = ""
  txtPassword.SetFocus
  Exit Sub
  Else
  
  strUserName = txtUsername.Text 'May need in the future project
   strName = oRs.Fields("FirstName") &amp; " " &amp; oRs.Fields("LastName")
   frmInstruction.Show
  </code></pre>
  
  <p>This is what I have tried so far:</p>
  
  <pre><code>Dim cmd As OleDbCommand = New OleDbCommand("SELECT * FROM Login WHERE  Username= '" &amp; txtUsername.Text &amp; "' AND password = '" &amp; txtPassword.Text &amp; "' ", oCn)
  
  Dim sdr As OleDbDataReader = cmd.ExecuteReader()
  
  If (sdr.Read() = True) Then
  
  strUserName = txtUsername.Text
  
  frmInstruction.Show()
  
  'but am having issue with this line of code: 
  strName = oRs.Fields("FirstName") &amp; " " &amp; oRs.Fields("LastName")
  </code></pre>