Wrox Programmer Forums
|
ASP.NET 1.x and 2.0 Application Design Application design with ASP.NET 1.0, 1.1, and 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.x and 2.0 Application Design section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old May 20th, 2004, 05:12 PM
Registered User
 
Join Date: May 2004
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default 'OracleConnection' is not defined.

I have a following code in the page. I have installed Oracle Client and did add to reference in the solution explorer. This example works in VB.Net but not in ASP.Net. Do you have any solution for this error message. Compiler generates error message that "system.data.OracleClient" Cannot be found. It looks like configuration of some files are missing. Your help is highly appreciated.



Thanks

Nagender


<%@ page language="VB" runat="server" %>
<%@ Import Namespace="System" %>
<%@ Import Namespace="System.Data" %>
<%@ Import Namespace="CoreLab.Oracle" %>
        <script Language="vb" runat="server" >
Dim oOracleConn As OracleConnection = New OracleConnection()
dim myConnString = "Data source=local.world;user id=user;password=userpw;"

     Dim myConnection As New OracleConnection(myConnString)
          myConnection.Open()
 </script>

 
Old May 24th, 2004, 07:21 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 1,998
Thanks: 0
Thanked 3 Times in 3 Posts
Default

Hello,

What is involved with the CoreLab.Oracle class? What does this do?

Brian
 
Old May 24th, 2004, 09:41 AM
Registered User
 
Join Date: May 2004
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Brian,

Thanks for your response. Core Lab dll also has same properties as OracleClient dll has, when I could not succeed in establishing connection with the database by using Oracleclient dll then I used Core Lab. Core Lab dll too did not connect the database then I switched to system.data.OracleClient dll. I added the reference in solution explorer and I could see properties of OracleClient dll in object browser. The end result is generation of an error message that system.data.OracleClient cannot be found and OracleConnection is not defined. This is very strange. The new code is:

<%@ page language="VB" runat="server" %>
<%@ Import Namespace="System" %>
<%@ Import Namespace="System.Data" %>
<%@ Import Namespace="system.Data.OracleClient" %>

<script Language="vb" runat="server" >
dim myConnString = "Data source=webediT.world;user id=webediuser;password=loanleveledi;"
Dim myConnection As = new OracleConnection(myConnString)

     myConnection.Open()

</script>

First I have installed VS.net and then Framework 1.1 version software was installed. Does it make any difference?

Thanks

Nagender






Similar Threads
Thread Thread Starter Forum Replies Last Post
ADODB.Connection user-defined type not defined Wall st Guru Excel VBA 2 March 26th, 2014 03:44 PM
Appl-defined or Object-defined error 1004 chp Excel VBA 3 April 4th, 2006 08:12 AM
User-defined type not defined (Icecream.mdb) dloren01 BOOK: Beginning Access VBA 0 June 22nd, 2005 10:36 PM
...not defined Adam H-W Javascript 2 October 28th, 2004 09:18 AM
Application-defined or object-defined error James Excel VBA 1 August 12th, 2003 11:50 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.