Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
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 tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old March 7th, 2012, 02:46 PM
Authorized User
Points: 134, Level: 2
Points: 134, Level: 2 Points: 134, Level: 2 Points: 134, Level: 2
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Feb 2012
Posts: 22
Thanks: 0
Thanked 4 Times in 4 Posts
Default Help with Chapter 15

I am working through the second try it out when I try to view the Genres.aspx page in the browser this is the error message i get.

Server Error in '/' Application.
--------------------------------------------------------------------------------

Parser Error
Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.

Parser Error Message: The 'ID' property of a control type System.Web.UI.WebControls.GridView cannot be applied through a control skin.

Source Error:


Line 1: <asp:GridView ID="GridView1" runat="server" CssClass="GridView">
Line 2: <HeaderStyle CssClass="GridViewHeaderStyle" />
Line 3: <PagerStyle CssClass="GridViewPagerStyle" />


Source File: /App_Themes/Management/GridView.skin Line: 1

It seems it is telling me that this is not a proper use of the asp tag GridView am I doing something wrong?

do I need a using statement in the skin file

Code:
<asp:GridView ID="GridView1" runat="server" CssClass="GridView">
  <HeaderStyle CssClass="GridViewHeaderStyle" />
  <PagerStyle CssClass="GridViewPagerStyle" />
  <SortedAscendingHeaderStyle CssClass="GridViewSortedAscendingHeaderStyle" />
  <SortedDescendingHeaderStyle CssClass="GridViewSortedDescendingHeaderStyle" />
</asp:GridView>
is the current of my GridView.skin

I also get this warning in the error list window

Warning 1 E:\Websites\BegASPNET\App_Themes\Management\GridVi ew.skin: ASP.NET runtime error: There is no build provider registered for the extension '.skin'. You can register one in the <compilation><buildProviders> section in machine.config or web.config. Make sure is has a BuildProviderAppliesToAttribute attribute which includes the value 'Web' or 'All'. E:\Websites\BegASPNET\App_Themes\Management\GridVi ew.skin 1 1 E:\Websites\BegASPNET\
Reply With Quote
  #2 (permalink)  
Old March 7th, 2012, 03:06 PM
Imar's Avatar
Wrox Author
Points: 72,045, Level: 100
Points: 72,045, Level: 100 Points: 72,045, Level: 100 Points: 72,045, Level: 100
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,083
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Hi there,

For the error, take a look at page 233. Controls defined in a Skin file can't have ID attributes.

For the build warning, take a look at page 234....

Cheers,

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!
Reply With Quote
The Following User Says Thank You to Imar For This Useful Post:
dansivan (July 27th, 2012)
  #3 (permalink)  
Old March 7th, 2012, 03:53 PM
Authorized User
Points: 134, Level: 2
Points: 134, Level: 2 Points: 134, Level: 2 Points: 134, Level: 2
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Feb 2012
Posts: 22
Thanks: 0
Thanked 4 Times in 4 Posts
Default

Thanks Imar but now I have another problem with it

I get the following error message with when I try to view the Genres.aspx in the browser

Line: 105
Error: Object expected

This is asscoiated with the jquery script at the bottom of the page when I choose to enter the debugger the whole script is highlighted in yellow right after the script tag.
Reply With Quote
  #4 (permalink)  
Old March 7th, 2012, 03:59 PM
Authorized User
Points: 134, Level: 2
Points: 134, Level: 2 Points: 134, Level: 2 Points: 134, Level: 2
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Feb 2012
Posts: 22
Thanks: 0
Thanked 4 Times in 4 Posts
Default

Never mind I got it working bad refference to the script file in the master page thanks for you help Happy Conding
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Chapter 15 thepianoguy BOOK: Professional iPhone and iPad Application Development 2 April 16th, 2011 07:39 AM
chapter 15 manal_sag BOOK: Beginning ASP 3.0 2 March 13th, 2006 04:48 PM
Chapter 15 rrlevron BOOK: Beginning ASP 3.0 0 November 17th, 2005 03:38 PM
Chapter 15!! studentinpain BOOK: Beginning ASP 3.0 16 March 12th, 2004 10:26 AM
Chapter 15 help Lorenzo_G BOOK: Beginning ASP 3.0 1 November 27th, 2003 01:00 PM



All times are GMT -4. The time now is 09:41 PM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.