Logo 
Search:

Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

Reagarding Impersonation of the Webpart

  Asked By: Raul    Date: Aug 16    Category: Sharepoint    Views: 627

I am working on one web part which shows all the
Administrators Details .but my requirement is it should display to all Users
(even though they r having Read Permissions).

How to Impersonate all the users to view the Web Part.

Share: 

 

2 Answers Found

 
Answer #1    Answered By: Janell Camacho     Answered On: Aug 16
 
Answer #2    Answered By: Julia Washington     Answered On: Aug 16

At Last we done the Impersonation to a Webpart . For more
Info Please Go through this.

www.sharepointblogs.com/.../alerts-not-working-\
in-moss.aspx

SPSite site = new SPSite("SiteCollection_Url");

SPWeb web  = site.OpenWeb();

SPUser user = web.AllUsers["User_Name"];

SPUserToken token = user.UserToken;

SPSite impersonatedSiteCollection = new SPSite("SiteCollection_Url", token);

 
Didn't find what you were looking for? Find more on Reagarding Impersonation of the Webpart Or get search suggestion and latest updates.