Student Database

Submitted by: 
Language: 
Visitors have accessed this post 4752 times.

This source code will perform basic operation of a database like record navigation, add new, and delete record.

  1. Imports System.Data.OleDb
  2.  
  3. Public Class frmStudentDB
  4.  
  5. Private Sub frmStudentDB_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
  6. 'TODO: This line of code loads data into the 'UniversityDataSet.Student' table. You can move, or remove it, as needed.
  7. Me.StudentTableAdapter.Fill(Me.UniversityDataSet.Student)
  8.  
  9. End Sub
  10.  
  11. Private Sub btnPrevious_Click(sender As System.Object, e As System.EventArgs) Handles btnPrevious.Click
  12. 'Moves to the previous record
  13. StudentBindingSource.MovePrevious()
  14. End Sub
  15.  
  16. Private Sub btnNext_Click(sender As System.Object, e As System.EventArgs) Handles btnNext.Click
  17. 'Moves to the next record
  18. StudentBindingSource.MoveNext()
  19. End Sub
  20.  
  21. Private Sub btnAddNew_Click(sender As System.Object, e As System.EventArgs) Handles btnAddNew.Click
  22. 'Adds a new record
  23. StudentBindingSource.AddNew()
  24. End Sub
  25.  
  26. Private Sub btnSave_Click(sender As System.Object, e As System.EventArgs) Handles btnSave.Click
  27. 'Saves the new record
  28. StudentBindingSource.EndEdit()
  29. StudentTableAdapter.Update(UniversityDataSet.Student)
  30. End Sub
  31.  
  32. Private Sub btnDelete_Click(sender As System.Object, e As System.EventArgs) Handles btnDelete.Click
  33. 'Deletes the current record
  34. StudentBindingSource.RemoveCurrent()
  35. End Sub
  36.  
  37. Private Sub btnExit_Click(sender As System.Object, e As System.EventArgs) Handles btnExit.Click
  38. 'Exits the program
  39. Me.Close()
  40. End Sub
  41. End Class

Note: Due to the size or complexity of this submission, the author has submitted it as a .zip file to shorten your download time. After downloading it, you will need a program like Winzip to decompress it.

Virus note: All files are scanned once-a-day by SourceCodester.com for viruses, but new viruses come out every day, so no prevention program can catch 100% of them.

FOR YOUR OWN SAFETY, PLEASE:

1. Re-scan downloaded files using your personal virus checker before using it.
2. NEVER, EVER run compiled files (.exe's, .ocx's, .dll's etc.)--only run source code.

Add new comment

Filtered HTML

  • Web page addresses and e-mail addresses turn into links automatically.
  • You may insert videos with [video:URL]
  • Allowed HTML tags: <a> <em> <strong> <cite> <blockquote> <code> <ul> <ol> <li> <dl> <dt> <dd> <table> <tr> <td> <th> <img> <h1> <h2> <h3> <iframe> [video]
  • You can enable syntax highlighting of source code with the following tags: <code>, <blockcode>, <asp>, <c>, <cpp>, <csharp>, <css>, <html4strict>, <java>, <javascript>, <mysql>, <php>, <python>, <sql>, <vb>, <vbnet>. The supported tag styles are: <foo>, [foo].
  • Lines and paragraphs break automatically.

Plain text

  • No HTML tags allowed.
  • Lines and paragraphs break automatically.
CAPTCHA
This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.