Logo 
Search:

Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

How to assign a user administrative rights to areas

  Asked By: Katie    Date: Jun 16    Category: Sharepoint    Views: 1185

How to assign a user administrative rights to areas like Topics, News, sub areas etc.

SPWeb web = SPControl.GetContextWeb(this.Context);
web.Site.CatchAccessDeniedException = false;
try
{
if (web.UserIsWebAdmin || web.UserIsSiteAdmin)
{
output.WriteLine("Hello");
}
}
catch( Exception ex)
{
output.Write(ex.Message);
}

If I drop this web part say in http://serverName/default.aspx, I see the message Hello, but If I drop this web part in areas say Topics( http://serverName/Topics/default.aspx), News etc. I don't see it. But administrator to operating system(super user) see it.

Any suggestions?

Share: 

 

No Answers Found. Be the First, To Post Answer.

 
Didn't find what you were looking for? Find more on How to assign a user administrative rights to areas Or get search suggestion and latest updates.




Tagged: