Database Connection at Design Time

Answer

Well-known member
Joined
Jul 2, 2002
Messages
46
Location
USA
Hi Guys,

Well im a newb at vb.net and im trying to access me dBase III database during design time using the Connection wizards thingy. Well it isnt working so well. I would like to use the Jet driver and i know i can becuase i have code that uses the jet provider to access the database during runtime ( code ). However i would really like to be able to set the connection up at design time.

So far what i do is click on the server explorer, and add a new connection to database. I choose the Jet 4.0 driver then click next, for the database name i enter the path to where the database is located BUT i DONOT enter the database name. I then goto the all tab and under "extended properties" type dbase III. This somewhat works, as when i click test connection it says everything is ok, but when i click OK, no component is created nor i can i browse my tables with the server explorer like i can with a access database. It seems like its not working!

Thanks for your help.

P.S. So far VB.net is much harder then vb6, with vb6s datacontrol it was very simple, and even the Microsoft ADO control was extremely simple to use.
 
Last edited by a moderator:
You could choose to skip the wizard and create the connection manually.
Code:
Dim objConnection As OLEDBConnection
objConnection = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; Data Source=D:\database.mdb;")
objConnection.Open()
Perform actions here
objConnection.Close()
 
Thanks for the reply!

That code works well for some stuff that iwant to do but i dont think it will allow me to do databinding at designtime will it?

if so could you point me in a direction that tells me how, as i cant find anything.
 
Thats a good question...i know its the academic verison as i got it free from microsoft along with windows XP at this seminar thing they held.

I jsut checked oin the cds and all it says is academic


"Visual Studio .NET Academic incorporates all the features of Visual Studio .NET Professional, plus several new instructionally targeted features, including Assignment Manager, student-specific documentation, and sample code. These features provide professors, instructors, and students with a superior development environment for academic use. "

i just pasted that from MSs website so im going to assume its the same as professional.
 
Back
Top