ODBC connection in :NET! Please Help

NWolfer
01-09-2004, 03:02 PM
Hello,

I have imported a VB6 program to .NET. The DataBase was used via ODBC but this do not work anymore. I can create the new connection in Server Explorer, this look like VB6 and it's simple.
My problem is to find the equivalent of the VB6 DataEnvironment. How do you use Table of the Connection in Visual Basic .NET?

Thanks in advance,

Nic

reboot
01-09-2004, 03:18 PM
There is no equivalent to the VB6 DataEnvironment in .Net

NWolfer
01-09-2004, 03:20 PM
There is no equivalent to the VB6 DataEnvironment in .Net
and what is the solution?

Optikal
01-09-2004, 07:24 PM
What are you trying to accomplish?

NWolfer
01-10-2004, 03:47 AM
What are you trying to accomplish?

I’m working with Visiual Studio Net since yesterday, so I have a lot to learn. Basically what I would like to do is to import all my VB6 programs to .NET. This has been done automatically but I lost access with the DataBase (via ODBC).

I have downloaded ODBC_Net from Microsoft and installed it. I do not know what to do with it and how to use it.

Any Help to have access to an Access DataBase with Visual Basic .NET will be appreciated.

Thanks,

Nicolas

NWolfer
01-10-2004, 03:52 PM
What are you trying to accomplish?

I’m working with Visiual Studio Net since yesterday, so I have a lot to learn. Basically what I would like to do is to import all my VB6 programs to .NET. This has been done automatically but I lost access with the DataBase (via ODBC).

I have downloaded ODBC_Net from Microsoft and installed it. I do not know what to do with it and how to use it.

Any Help to have access to an Access DataBase with Visual Basic .NET will be appreciated.

Thanks,

Nicolas

OK it's work now with :

Imports System.Data
Imports Microsoft.Data.Odbc


Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim connection2 As OdbcConnection
connection2 = New OdbcConnection("dsn=Josef_DB")
connection2.Open()
MsgBox("Connected")
Connection2.Close()

End Sub
End Class

Thanks,

Nicolas

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum