Wrox Programmer Forums
|
BOOK: Beginning ASP.NET 4 : in C# and VB
This is the forum to discuss the Wrox book Beginning ASP.NET 4: in C# and VB by Imar Spaanjaars; ISBN: 9780470502211
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET 4 : in C# and VB 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 March 16th, 2014, 11:44 AM
Registered User
 
Join Date: Mar 2014
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default Chapter 13 Try It Out pg 464

I am using VS 2012 and after copy & pasting the source code from the downloads, I continue to get the following compilation error on the Reviews.aspx content page.

Compiler Error Message: CS0103: The name 'GetBooleanText' does not exist in the current context

Line 11: <asp:TemplateField HeaderText="Authorized" SortExpression="Authorized">
Line 12: <ItemTemplate>
Line 13: <asp:Label ID="AuthorizedLabel" runat="server" Text='<%# GetBooleanText(Eval("Authorized")) %>' />
Line 14: </ItemTemplate>
Line 15: </asp:TemplateField>
 
Old March 16th, 2014, 12:09 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Did you also create / copy that method to the Code Behind of the page?

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
 
Old March 16th, 2014, 07:18 PM
Registered User
 
Join Date: Mar 2014
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi Imar,

Yes, I included the GetBoolean method on the code behind file.
The problem was that I included it on the code behind for the
Genre.aspx instead of the code behind for the Reviews.aspx page.
Both look so similar that somehow I got them mixed up.

The error is gone. I checked both files but it never occurred to
me that I entered the code on the wrong file. What a silly
mistake. Nevertheless, thanks again for your insight.

Have a great day,
Adrianne





Similar Threads
Thread Thread Starter Forum Replies Last Post
Ch 13, Pg 469, error on EndEditing sub supdike BOOK: Beginning ASP.NET 4 : in C# and VB 1 June 5th, 2012 02:34 PM
Chapter 13 thepianoguy BOOK: Professional iPhone and iPad Application Development 3 April 6th, 2011 09:42 AM
pg 464 BoxOperators.h sudhanshu631 BOOK: Ivor Horton's Beginning Visual C++ 2008 ISBN: 978-0-470-22590-5 1 February 18th, 2010 08:03 PM
Chap 13 pg 428: Where is the LInq to SQL class? tomche BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 6 July 2nd, 2009 07:25 AM
Chapter 13 Try It Out Pg. 460 Broken Images workib BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 4 September 19th, 2008 10:29 AM





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