title: How to set submit button in vb.net
body: <p>When I want to calculate the result, I have entered in the textbox. </p>
  
  <p>I connected them successfully with my local database. </p>
  
  <p>But I use these codes to terminate the Score entry if the Students list ended.</p>
  
  <pre><code>Dim AssessmentRecords = Select p
                          From p In db.Assessments
                          Where p.Class = cboClass.Text
      If RecordPosition + 1 &lt; AssessmentRecords.Count Then
         MsgBox("End of Records reached!", MsgBoxStyle.Exclamation + MsgBoxStyle.OkOnly)
         Exit Sub
      End If
  </code></pre>
  
  <p>When I debugged the software, I can't actually enter the score it keeps telling me "End of Records reached"</p>
  
  <p>I don't know how to deals with the problem and sometime I can put only for one person and then terminates and I use LINEQ to SQL in my connection to local database. </p>
  
  <p>I will appreciate any help, thank you! </p>