Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

SPControl security

  Asked By: Ernie    Date: Nov 24    Category: Sharepoint    Views: 738

I am using the SPControl class to figure out the current user that is
logged in and there role in a custom web part. I run into a security
error when I access the portal as a non admin user since they do not
have the privalages to execute the SPControl class.

Any suggestions on how to configure this security so my web part will
be able to execute under any member of the portal.



2 Answers Found

Answer #1    Answered By: Dakota Shaffer     Answered On: Nov 24

you will have to use impersonation to get round this.
i did the very same thing a few months back.

Answer #2    Answered By: Ted Gilmore     Answered On: Nov 24

The problem I ran into with impersonation was that it would return
the roles of the user  I set to impersonate versus the current  logged
in user.

Didn't find what you were looking for? Find more on SPControl security Or get search suggestion and latest updates.