There are some occasions in which we need to give anonymous access to SharePoint Application Pages , but on that webapplication does not give the anonymous access. Examples like Registration Page, Forgot Password page. So how to do that?
We need to do three things for that.
1. protected override bool AllowAnonymousAccess
{
get
{
return true;
}
}
2. Instead, you need to use another base class for your anonymous application page called UnsecuredLayoutsPageBase. MSDN reference at: http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.webcontrols.unsecuredlayoutspagebase.aspx
3. Please make sure we don't use DynamicMasterPageFile="~/masterurl/default.master" your application layout pag .aspx file.
change it to MasterPageFile="~/_layouts/simple.master"
It still does not work. Please help
ReplyDeleteHi Divyesh
DeleteSo which Error still you are getting? Did you follow all these three steps?
Disha Shah
Works well
ReplyDeleteThank you!!!
DeleteI have tried this code and it's working fine. It will help me in my Sharepoint Development projects. Thanks for sharing..
ReplyDeleteSunny
DeleteThank you and I am glad it helped you in your project!!!Keep it up the good work.
Disha Shah
Thank you Disha for this post. It solved my issue.
ReplyDeleteTake Care.
Manny
I am glad it helped you in your work!!!
DeleteKeep coding!!!
Disha Shah
Hi Disha,
ReplyDeleteI want to develop a registration page in sharepoint2013.
Email, Password,confirmpassword.
and this data should store in a sql.
This is internet project.
Please guide me.
Thank you,
Sowjanya.