Last post Mar 29, 2012 09:13 PM by Decker Dong - MSFT
Participant
893 Points
2009 Posts
Mar 28, 2012 11:19 AM|jagdipa|LINK
I have a Dynamic Data website. In the RegisterRoutes() for Global.aspx, I need to ensure that the user is authenticated.
This is not working - I get an 'Object Reference not set to an instance of an object' error.
What am I doing wrong?
(I have other Web Applications where I can access the User.IsAuthenticated through the Global.aspx Session_Start event with no problems)
All-Star
17916 Points
5681 Posts
MVP
Mar 29, 2012 05:22 AM|sjnaughton|LINK
Hi jagdipa, there is no reason why this should not work, have you tried this in a vanila Dynamic Data project/website?
94130 Points
18109 Posts
Mar 29, 2012 09:13 PM|Decker Dong - MSFT|LINK
jagdipa I have a Dynamic Data website. In the RegisterRoutes() for Global.aspx, I need to ensure that the user is authenticated. This is not working - I get an 'Object Reference not set to an instance of an object' error. What am I doing wrong?
Please re-create another proj and have a try with that。
If this still fails,plz show us your codes。
Reguards!
Participant
893 Points
2009 Posts
Dynamic Data Website and HttpContext.Current.User.IsAuthenticated
Mar 28, 2012 11:19 AM|jagdipa|LINK
I have a Dynamic Data website. In the RegisterRoutes() for Global.aspx, I need to ensure that the user is authenticated.
This is not working - I get an 'Object Reference not set to an instance of an object' error.
What am I doing wrong?
(I have other Web Applications where I can access the User.IsAuthenticated through the Global.aspx Session_Start event with no problems)
All-Star
17916 Points
5681 Posts
MVP
Re: Dynamic Data Website and HttpContext.Current.User.IsAuthenticated
Mar 29, 2012 05:22 AM|sjnaughton|LINK
Hi jagdipa, there is no reason why this should not work, have you tried this in a vanila Dynamic Data project/website?
Always seeking an elegant solution.
All-Star
94130 Points
18109 Posts
Re: Dynamic Data Website and HttpContext.Current.User.IsAuthenticated
Mar 29, 2012 09:13 PM|Decker Dong - MSFT|LINK
Please re-create another proj and have a try with that。
If this still fails,plz show us your codes。
Reguards!