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: ASP.NET Website Programming Problem-Design-Solution
This is the forum to discuss the Wrox book ASP.NET Website Programming: Problem - Design - Solution, Visual Basic .NET Edition by Marco Bellinaso, Kevin Hoffman; ISBN: 9780764543869
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: ASP.NET Website Programming Problem-Design-Solution 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
 
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old March 11th, 2005, 08:58 PM
Registered User
 
Join Date: Mar 2005
Location: , , .
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Siteheader won't get thru compiler

VB code, VS2003. I have followed the book up thru where modules begins and integrated into my existing website. I believe my problems started when I added the "philepage" to my homepage and now every time I hit the F5 it errors out on the line " If CONTEXT.User.Identity.IsAuthenticated Then" by saying this is not an object. Somehow this line worked on my homepage, but now it is not recognized.

Any suggestions on how I can trace the compiler? I don't know exactly where it is falling apart.

HELP! Thanx, Tom.

  #2 (permalink)  
Old March 13th, 2005, 02:55 PM
Authorized User
 
Join Date: Jun 2003
Location: Bolingbrook, IL, USA.
Posts: 17
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi Tom -

You may want to go to the codebehind pages of the .aspx pages (hit F7 in Visual Studio), scroll down to the section called "Web Form Designer generated code" (usually collapsed) and check that OnInit(EventArgs e) looks like this:

override protected void OnInit(EventArgs e)
{
  base.OnInit(e);
  InitializeComponent();
}

Make sure that base.OnInit(e) is above InitializeComponent() so that the Phile "page base" is called first. See if this works.

Allen

-----
mencher cat, mencher cat. boo. cattydear. what a lovely!
  #3 (permalink)  
Old March 13th, 2005, 05:59 PM
Registered User
 
Join Date: Mar 2005
Location: , , .
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanx for idea. I have in fact resolved this by correcting an error in NEW() event in the siteidentity.vb page. I commented it out until I could understand what was happening. Now I know. Issue closed, thanx, Tom.

 


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
Compiler Romaunt V. Intro Programming 2 October 18th, 2008 06:27 AM
Context.User in siteheader.ascx.cs scottf BOOK: ASP.NET Website Programming Problem-Design-Solution 7 November 3rd, 2005 12:52 PM
Cannot compile siteheader.ascx.cs golfvilla BOOK: ASP.NET Website Programming Problem-Design-Solution 6 January 19th, 2004 06:27 PM
For all who need a C/C++ compiler... Ammiel C++ Programming 1 July 17th, 2003 01:42 PM



All times are GMT -4. The time now is 08:07 AM.


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