Type 'OdbcConnection' is not defined.

farid

Member
Joined
May 24, 2003
Messages
9
Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

Compiler Error Message: BC30002: Type OdbcConnection is not defined.


<%@ Page LANGUAGE="VB"%>
<%@ Import Namespace="System.Data" %>
<%@ Import Namespace="System.Data.ODBC" %>
<SCRIPT LANGUAGE="VB" RUNAT="server">
Sub Page_Load(Sender As Object, E As EventArgs)
Dim oConn As OdbcConnection
Dim sConnString As String
sConnString = "DNS=band"
oConn = New OdbcConnection(sConnString)
oConn.Open()
oConn.Close()
End Sub
</SCRIPT>
<HTML>
<BODY>
Opening a Connection with ODBC!
</BODY>
</HTML>

there is a ODBC connectoion named band.........
can any on help
 
Just want to check with you, do you use .NET Framework 1.0 or 1.1? If 1.0, did you install ODBC? because .NET Framework 1.0 original did not support ODBC, you need to install it.
 
Back
Top