Wrox Programmer Forums
|
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 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 November 12th, 2004, 09:46 AM
Authorized User
 
Join Date: Oct 2004
Posts: 12
Thanks: 0
Thanked 0 Times in 0 Posts
Default A doubt in the EditRole.aspx.cs?

There is a function in the EditRole.aspx.cs

private void Page_Load(object sender, System.EventArgs e)
        {
            // Put user code to initialize the page here
            PhilePrincipal currentPrincipal = (PhilePrincipal)Context.User;
            if (!currentPrincipal.HasPermission((int)AccountsPerm issions.UpdateRoles))
            {
                Response.Write("You don't have sufficient permission to be using this page.");
                Response.End();
            }

            if (!Page.IsPostBack)
            {
                DoInitialDataBind();
            }
        }

I can't understand what is about with the "(PhilePrincipal)Context.User"

Who can tell me?



 
Old November 13th, 2004, 05:55 PM
Authorized User
 
Join Date: Nov 2003
Posts: 37
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to seanmayhew
Default

That casts the default context.user into the principal object created with the file






Similar Threads
Thread Thread Starter Forum Replies Last Post
Keyboard shortcut to go from cs to aspx file roman BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 3 June 20th, 2008 01:28 PM
ShoppingCart.aspx.cs - System.FormatException ??? kalel_4444 BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 1 April 16th, 2008 01:00 AM
New.aspx works but login.aspx fails Validation nigelhamilton BOOK: ASP.NET Website Programming Problem-Design-Solution 8 September 13th, 2004 02:29 AM
HowTo Pass Form data from Page1.aspx to Page2.aspx dati ASP.NET 1.0 and 1.1 Basics 6 January 27th, 2004 06:57 AM





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