Hi,

I'm new to VB.Net (surprise surprise!) and am having trouble with connecting to an .mdb file. I have done it 100s of times in vb.6, so if somebody could help me i'd be most appreciative.

Is somebody able to translate this VB.6 code into VB.Net:

Code:
' Define Global Variables
Public gconDatabase As New ADODB.Connection

Public Function ConnectToDatabase()
    gconDatabase.ConnectionString = "Data Source=" & gcDatabasePath & ";" & _
                                    "Persist Security Info=False"
    gconDatabase.Provider = "Microsoft.Jet.OLEDB.4.0"
    gconDatabase.Properties("Jet OLEDB:database Password").Value = gcDatabasePassword
    gconDatabase.Open 
end function
?

thanks

stingrae