p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


  Return to Index  

aspdotnet_website_programming thread: Problem connecting to database


Message #1 by "Brian" <bbaum@w...> on Thu, 9 May 2002 20:05:07
I am new to asp.NET and ado.NET and I am having trouble connecting to my 
database.  I am getting an error in my first few lines of code when 
importing namespaces.  

My import lines of code look like this:

<%@Import Namespace=System.Data"%>
<%@Import Namespace=System.Data.ADO%>

I also tried:

<%@Import Namespace=System.Data"%>
<%@Import Namespace=System.Data.OLEDB%>


THE ERROR LOOKS LIKE THIS:

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: BC30648: String constants must end with a double 
quote.

Source Error:

 

Line 17: Imports System.Collections.Specialized
Line 18: Imports System.Configuration
Line 19: Imports System.Data"
Line 20: Imports System.Data.ADO
Line 21: Imports System.Text

Source File: C:\WINDOWS\Microsoft.NET\Framework\v1.0.3705\Temporary 
ASP.NET Files\webproject2\61b6767c\d88a80c7\gvchrqnt.0.vb    Line: 19

Does anyone know what the problem could be?  Thanks
 
Message #2 by "Minh T. Nguyen" <nguyentriminh@y...> on Thu, 9 May 2002 12:14:08 -0700
Brian,

	You have to put the namespaces in quotes, so both the beginning
and the ending quote:

	<%@Import Namespace="System.Data"%>

Minh.
	

-----Original Message-----
From: Brian [mailto:bbaum@w...] 
Sent: Thursday, May 09, 2002 8:05 PM
To: Website Programming with ASP.NET
Subject: [aspdotnet_website_programming] Problem connecting to database


I am new to asp.NET and ado.NET and I am having trouble connecting to my

database.  I am getting an error in my first few lines of code when 
importing namespaces.  

My import lines of code look like this:

<%@Import Namespace=System.Data"%>
<%@Import Namespace=System.Data.ADO%>

I also tried:

<%@Import Namespace=System.Data"%>
<%@Import Namespace=System.Data.OLEDB%>


THE ERROR LOOKS LIKE THIS:

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: BC30648: String constants must end with a double

quote.

Source Error:

 

Line 17: Imports System.Collections.Specialized
Line 18: Imports System.Configuration
Line 19: Imports System.Data"
Line 20: Imports System.Data.ADO
Line 21: Imports System.Text

Source File: C:\WINDOWS\Microsoft.NET\Framework\v1.0.3705\Temporary 
ASP.NET Files\webproject2\61b6767c\d88a80c7\gvchrqnt.0.vb    Line: 19

Does anyone know what the problem could be?  Thanks
 


  Return to Index