Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| 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 27th, 2012, 07:01 AM
Authorized User
Points: 170, Level: 3
Points: 170, Level: 3 Points: 170, Level: 3 Points: 170, Level: 3
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Dec 2011
Posts: 43
Thanks: 11
Thanked 0 Times in 0 Posts
Default Problem page 636.

Hi, ive just tried to open my Login.aspx page and received this weird error:

Code:
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: CS1010: Newline in constant

Source Error:

[No relevant source lines]
Dont know what it could mean, any help would be appreciated!

Nick
Reply With Quote
  #2 (permalink)  
Old March 27th, 2012, 10:17 AM
Imar's Avatar
Wrox Author
Points: 72,073, Level: 100
Points: 72,073, Level: 100 Points: 72,073, Level: 100 Points: 72,073, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Hi there,

Can you post the code for that 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!
Reply With Quote
  #3 (permalink)  
Old March 27th, 2012, 11:04 AM
Authorized User
Points: 170, Level: 3
Points: 170, Level: 3 Points: 170, Level: 3 Points: 170, Level: 3
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Dec 2011
Posts: 43
Thanks: 11
Thanked 0 Times in 0 Posts
Default

Hi Imar, yes here it is. There wasnt any code for it just markup:

One other thing that might be of interest is that i tried to open the securty tab in WSAT and got the same error.

Code:
<%@ Page Title="Log in to Planet Wrox" Language="C#" MasterPageFile="~/MasterPages/Frontend.master" AutoEventWireup="true" CodeFile="Login.aspx.cs" Inherits="Login" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="cpMainContent" runat="Server">
    <h1>Log in to Planet Wrox<asp:LoginView ID="LoginView1" runat="server">
        <AnonymousTemplate>
            <asp:Login ID="Login1" runat="server" 
          CreateUserText="Sign Up for a New Account at Planet Wrox" 
          CreateUserUrl="SignUp.aspx" Font-Bold="True" Font-Names="Arial" 
            Font-Size="Small" Width="250px">
            </asp:Login>
            <br />
            <br />
            <asp:PasswordRecovery ID="PasswordRecovery1" runat="server">
            <MailDefinition subject="Your new Password for PlanetWrox.com"></MailDefinition>
            </asp:PasswordRecovery>
        </AnonymousTemplate>
        <LoggedInTemplate>
            You are already logged in
        </LoggedInTemplate>
        </asp:LoginView>
    </h1>
    <asp:LoginStatus ID="LoginStatus1" runat="server" />
</asp:Content>
Reply With Quote
  #4 (permalink)  
Old March 27th, 2012, 11:17 AM
Imar's Avatar
Wrox Author
Points: 72,073, Level: 100
Points: 72,073, Level: 100 Points: 72,073, Level: 100 Points: 72,073, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Very odd, as this code looks OK to me.

Could there be an issue in web.config? Did you recently change something?

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
  #5 (permalink)  
Old March 27th, 2012, 11:22 AM
Authorized User
Points: 170, Level: 3
Points: 170, Level: 3 Points: 170, Level: 3 Points: 170, Level: 3
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Dec 2011
Posts: 43
Thanks: 11
Thanked 0 Times in 0 Posts
Default

Today ive been adding this code to my web.config file so unless theres a problem with some of this :

Code:
        <profile>
            <properties>
                <add name ="FirstName" />
                <add name ="LastName" />
                <add name ="DateOfBirth" type="System.DateTime" />
                <add name ="Bio" />
                <add name ="FavoriteGenres" 
                                type="System.Collections.Generic.List'1[System.Int32]"/>
            </properties>
        </profile>
        <membership>
            <providers>
                <clear /><add name="AspNetSqlMembershipProvider" type="System.Web.Security.SqlMembershipProvider, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" connectionStringName="LocalSqlServer" enablePasswordRetrieval="false" enablePasswordReset="true" requiresQuestionAndAnswer="false" applicationName="/" requiresUniqueEmail="false" passwordFormat="Hashed" maxInvalidPasswordAttempts="5" minRequiredPasswordLength="6" minRequiredNonalphanumericCharacters="1" passwordAttemptWindow="10" passwordStrengthRegularExpression=""/>
            </providers>
        </membership>
Reply With Quote
  #6 (permalink)  
Old March 27th, 2012, 11:38 AM
Imar's Avatar
Wrox Author
Points: 72,073, Level: 100
Points: 72,073, Level: 100 Points: 72,073, Level: 100 Points: 72,073, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Ah, there we have it. Take a look at this:

Quote:
type="System.Collections.Generic.List'1[System.Int32]"/>
You're using a quote (') instead of the back tick (`).

Take a look at page 623 / 624 for more details.

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:
Nick Makin (March 27th, 2012)
  #7 (permalink)  
Old March 27th, 2012, 11:51 AM
Authorized User
Points: 170, Level: 3
Points: 170, Level: 3 Points: 170, Level: 3 Points: 170, Level: 3
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Dec 2011
Posts: 43
Thanks: 11
Thanked 0 Times in 0 Posts
Default

Ahhh thank you! Ill have a look and change that now.

Thanks again for the help Imar,

Nick
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 2 - page 41 problem creating the page.. jorjiana BOOK: Beginning Oracle Application Express ISBN: 9780470388372 2 August 22nd, 2009 04:25 AM
problem in master page bond007 ASP.NET 2.0 Basics 1 April 23rd, 2009 12:32 PM
problem about page display bbqlee Access 1 July 16th, 2006 02:06 AM
Ch. 18, page 636 Vera BOOK: Beginning VB.NET 2nd Edition/Beginning VB.NET 2003 0 March 18th, 2005 06:09 PM
Problem In refreshing a page. zaeem Classic ASP Components 2 November 4th, 2003 12:42 AM



All times are GMT -4. The time now is 10:43 AM.


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