Start New Discussion within our Software Development Community


When i First start my VB6 program with data report it works fine. The report displayed directly. but when i try to open other programs in other directory and then when i re-run my program in data report operation a msgbox appear "Please Enter MS Jet OLE DB Initialization Information"

Data Source
Provider String
Open mode.

It only occurs when i try to open other file in different directory. Everytime i open other file in other directory this message appear. Anybody can help me to fix this problem and how to set my original path so when i change directory and i return to my program maybe it will works fine again.

Thankyou in advance

Put this in Data Environment Initialization

Connection1.ConnectionString="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & App.Path & "\sample.mdb" & ";Persist security Info=False"

hope that would help...

hi there, i have got this coding but its not executing...
Set db = OpenDatabase(App.Path & "\student"
my m.Access file is called student, but am getting a msg saying that it couldnt find the file student and gives the address where the file is..please help, i think there should be someting wrong in da coding...

Don't forget the files extension... App.Path & "\student.mdb"

Also: To set the path, use ChDir (see help)

Good Luck

My vb6 application opens the access data base with the vb6 database name property of the Data1 control. How can I change this to open with explicit coding in the vb coding so I can change the path in a single location?

@zp18, start a NEW and your OWN thread by clicking THIS link. You will not get any help from members by hijacking others threads.

'Better late than never

db.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & StrDir & "SampleDB.mdb"
This article has been dead for over six months. Start a new discussion instead.