Posted by: Sourav | March 25, 2015

Connect access with Visual Basic 2012


Imports System.Data.OleDb

Public Class Form1

    Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
        Dim myconn As OleDbConnection
        myconn = New OleDbConnection(“Provider=Microsoft.Jet.OLEDB.4.0;Data Source=E:\Sourav.MDB”)
        myconn.Open()
        MessageBox.Show(“Connection successful”, “Sourav”)

    End Sub
End Class

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Categories

%d bloggers like this: