Wrox Programmer Forums
|
BOOK: Beginning ASP.NET Databases Also see the forum ASP Databases for more general discussions of ASP database issues not directly related to these books.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET Databases 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 September 9th, 2006, 05:24 AM
Friend of Wrox
 
Join Date: May 2005
Posts: 227
Thanks: 1
Thanked 7 Times in 7 Posts
Default Problem: Chaptr 4 -Data Reader Example

I am having a problem getting the Advance Data Reader Example, pp.100-101 to execute successfully. Reviewing the example on p. 100, according to the namespace System.Data.SqlClient, the database should be a SQL Server db. However according to the last line, under 1., the database used is NWind, which in my downloaded db's is a MS Access db. I changed the last line to reflect the northwind sql db and I am getting the error message: Connection String has not been initialize. I added the Trace="true" this is what I received:

Version Information: Microsoft .NET Framework Version:1.1.4322.2032; ASP.NET Version:1.1.4322.2032
Request Details
Session Id: lcxldsmq3ce3xj45jcmw5mm1 Request Type: GET
Time of Request: 9/9/2006 2:40:21 AM Status Code: 500
Request Encoding: Unicode (UTF-8) Response Encoding: Unicode (UTF-8)
Trace Information
Category Message From First(s) From Last(s)
aspx.page Begin Init
aspx.page End Init 0.000025 0.000025
Unhandled Execution Error
The ConnectionString property has not been initialized.
  at System.Data.SqlClient.SqlConnection.Open()
  at ASP.Datareader_aspx.Page_Load(Object Source, EventArgs E)
  at System.Web.UI.Control.OnLoad(EventArgs e)
  at System.Web.UI.Control.LoadRecursive()
  at System.Web.UI.Page.ProcessRequestMain() 0.014846 0.014822
Control Tree
Control Id Type Render Size Bytes (including children) Viewstate Size Bytes (excluding children)
Cookies Collection
Name Value Size
ASP.NET_SessionId lcxldsmq3ce3xj45jcmw5mm1 42

I even Commented the Dim String Connection statement and falling back to the SQL Connection String that worked in previous examples and I still get the Connection String error.

Any and all assistance is welcomed. Thanks in advance.
__________________
Disclaimer: The above comments are solely the opinion of one person and not to be construed as a directive or an incentive to commit fraudulent acts.
 
Old September 10th, 2006, 12:05 AM
Friend of Wrox
 
Join Date: May 2005
Posts: 227
Thanks: 1
Thanked 7 Times in 7 Posts
Default

To this forum:

I have resolved the problem and this was definitely a "user"(me) error.

Well moving on to Web Server Controls.





Similar Threads
Thread Thread Starter Forum Replies Last Post
Data reader checking.... janees ASP.NET 1.0 and 1.1 Professional 1 March 11th, 2007 06:09 AM
sql data reader problem MunishBhatia ASP.NET 2.0 Professional 0 December 9th, 2006 05:51 AM
oracle data reader silvia C# 10 February 2nd, 2006 07:30 AM
Fill data set from data reader sunil menghani ADO.NET 3 March 29th, 2005 07:08 AM





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