Imports System.IO
Imports System.Data.OleDb
Public Class Form2
    Dim conn As OleDbConnection
    Dim sql As OleDbCommand
    Dim rs As OleDbDataReader

    Private Sub Form2_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
        conn.Close()
    End Sub
    Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        conn = New OleDbConnection
        conn = New OleDbConnection("provider=microsoft.jet.oledb.4.0;data source=" & Application.StartupPath & "\Test_Evren.mdb")
        conn.Open()
        sql = New OleDbCommand("Select * from Tablo1;", conn)
        rs = sql.ExecuteReader
        Do While rs.Read
            'Buraya yeni satır ekleme kodu yazılacak
            'Buraya datagiride DB'den veri girilecek
            Me.GridView1.AddNewRow()

        Loop
    End Sub

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        MsgBox("Henüz kod yazılmadı.Uygun kodlar bulunduğunda yazılacak")
    End Sub
End Class