Wrox Programmer Forums
|
BOOK: Beginning ASP.NET 1.0
This is the forum to discuss the Wrox book Beginning ASP.NET 1.0 with C# by Chris Goode, John Kauffman, Christopher L. Miller, Neil Raybould, S. Srinivasa Sivakumar, Dave Sussman, Ollie Cornes, Rob Birdwell, Matt Butler, Gary Johnson, Ajoy Krishnamoorthy, Juan T. Llibre, Chris Ullman; ISBN: 9780764543708
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET 1.0 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 April 30th, 2004, 11:25 AM
Authorized User
 
Join Date: Apr 2004
Posts: 19
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to mahir
Default Ch15 FeaturedBook.ascx

Hi Another problem.

<%@ Control Debug="True" Language="VB" %>
<%@ import Namespace="System.Data" %>
<%@ import Namespace="System.Data.OleDb" %>
<%
    Dim ConnectString As String
    ConnectString = "Provider=Microsoft.Jet.OleDb.4.0;" & _
                        "Data Source = D:\BegASPNET\Ch15\WroxShop.mdb"

    Dim SQLString As String
    SQLString = "Select Tiltle, ISBN From Books"

    Dim MyConnection As New OleDbConnection(ConnectString)
    Dim MyCommand As New OleDbCommand(SQLString, MyConnection)

    Dim MyDataReader As OleDbDataReader
    Dim ResultString As String

    MyConnection.Open()
    MyDataReader = MyCommand.ExecuteReader()

    ResultString = "<table><tr><td class = 'datatablehead'>" & _
                    "Today's Featured Books:</td></tr>"

    Do While MyDataReader.Read()

        ResultString += "<tr><td class='datatable'>"
        ResultString += "<a href='http://www.wrox.com/ACON11.asp?ISBN="
        ResultString += MyDataReader("ISBN") & "' target='new'>"
        ResultString += MyDataReader("Title") & "</a>"

    Loop

    ResultString += "</table>"

    Response.Write(ResultString)

    MyDataReader.Close()
    MyConnection.Close()

%>

No value given for one or more required parameters.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Data.OleDb.OleDbException: No value given for one or more required parameters.

Source Error:


Line 19:
Line 20: MyConnection.Open()
Line 21: MyDataReader = MyCommand.ExecuteReader()
Line 22:
Line 23: ResultString = "<table><tr><td class = 'datatablehead'>" & _


Source File: D:\BegASPNET\Ch15\featuredbooks.ascx Line: 21


Mahir Ali Ahmed
__________________
Mahir Ali Ahmed
 
Old May 1st, 2004, 02:54 AM
Authorized User
 
Join Date: Apr 2004
Posts: 19
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to mahir
Default

Hey Guys

I really need help

Thanks

Mahir Ali Ahmed
 
Old May 1st, 2004, 04:27 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 996
Thanks: 2
Thanked 11 Times in 11 Posts
Send a message via Yahoo to melvik
Default

dear Ahmed:
Code:
SQLString = "Select Title, ISBN From Books"
NOT
Code:
SQLString = "Select <s>Tiltle</s>, ISBN From Books"
Pay more attention, I was looking for ur codes & all was fine (although i work with C#)

Always:),
Hovik Melkomian.
 
Old May 1st, 2004, 07:05 AM
Authorized User
 
Join Date: Apr 2004
Posts: 19
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to mahir
Default

Thanks Melvik I will be more carefull from nect time.
Thank you very much for your help. I realy like wrox books because they have that wonderfull forum where wonderfull people always ready to help.

Thanks once again.

Mahir Ali Ahmed
 
Old May 1st, 2004, 09:09 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 996
Thanks: 2
Thanked 11 Times in 11 Posts
Send a message via Yahoo to melvik
Default

ur welcome! never mind:D
pleasure to be helpfull.

Always:),
Hovik Melkomian.





Similar Threads
Thread Thread Starter Forum Replies Last Post
Working Code - Ch15 slurp56 BOOK: Professional PHP 5 ISBN: 978-0-7645-7282-1 3 April 24th, 2013 10:32 AM
Page 811; Ch15 Nick Y BOOK: Ivor Horton's Beginning Visual C++ 2005 0 July 24th, 2006 02:22 PM
Errata,book,Ch15,P470 din BOOK: Professional JavaScript for Web Developers ISBN: 978-0-7645-7908-0 1 March 14th, 2006 06:50 PM
Ch15 CodeBehind mahir BOOK: Beginning ASP.NET 1.0 2 May 8th, 2004 01:58 AM
ch15: can't get JSTL to be recognized brownale2k JSP Basics 1 August 8th, 2003 04:32 PM





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