WSS3 hide web part if permissions don't exist<p align=left>I have several web part pages that managers will be using as a company dashboard. The problem that I have is that instead of just not showing up to read only users, the web parts show an access denied error. Is there a way to simply hide the web part if the user does not have the appropriate user permissions?</p> <p> </p> <p align=left>I am using Sharepoint Services 3.</p> <p align=left> </p> <p align=left>Any suggestions are appreciated, thanks,</p> <p align=left> </p> <p align=left>Jason</p>© 2009 Microsoft Corporation. All rights reserved.Mon, 06 Jul 2009 14:50:51 Z106ab22e-ded2-42d3-92f0-45b2ebbc54d2http://social.msdn.microsoft.com/Forums/en-US/sharepointcustomization/thread/106ab22e-ded2-42d3-92f0-45b2ebbc54d2#106ab22e-ded2-42d3-92f0-45b2ebbc54d2http://social.msdn.microsoft.com/Forums/en-US/sharepointcustomization/thread/106ab22e-ded2-42d3-92f0-45b2ebbc54d2#106ab22e-ded2-42d3-92f0-45b2ebbc54d2JasonD240http://social.msdn.microsoft.com/Profile/en-US/?user=JasonD240WSS3 hide web part if permissions don't exist<p align=left>I have several web part pages that managers will be using as a company dashboard. The problem that I have is that instead of just not showing up to read only users, the web parts show an access denied error. Is there a way to simply hide the web part if the user does not have the appropriate user permissions?</p> <p> </p> <p align=left>I am using Sharepoint Services 3.</p> <p align=left> </p> <p align=left>Any suggestions are appreciated, thanks,</p> <p align=left> </p> <p align=left>Jason</p>Tue, 31 Jul 2007 20:15:07 Z2007-07-31T20:15:07Zhttp://social.msdn.microsoft.com/Forums/en-US/sharepointcustomization/thread/106ab22e-ded2-42d3-92f0-45b2ebbc54d2#910cd34a-e812-42e8-9bb1-23c8971e0e97http://social.msdn.microsoft.com/Forums/en-US/sharepointcustomization/thread/106ab22e-ded2-42d3-92f0-45b2ebbc54d2#910cd34a-e812-42e8-9bb1-23c8971e0e97Rich McGuirehttp://social.msdn.microsoft.com/Profile/en-US/?user=Rich%20McGuireWSS3 hide web part if permissions don't exist<p align=left>I know Audiences themselves don't exist in WSS 3, but you might still be able to apply audience filtering on Web Parts w/ SharePoint groups (done by modifying the properties of the web part)</p>Wed, 01 Aug 2007 20:47:40 Z2007-08-01T20:47:40Zhttp://social.msdn.microsoft.com/Forums/en-US/sharepointcustomization/thread/106ab22e-ded2-42d3-92f0-45b2ebbc54d2#d9050f03-675e-4f5a-8f21-de333bebf780http://social.msdn.microsoft.com/Forums/en-US/sharepointcustomization/thread/106ab22e-ded2-42d3-92f0-45b2ebbc54d2#d9050f03-675e-4f5a-8f21-de333bebf780Suchii _www.bewise.fr_http://social.msdn.microsoft.com/Profile/en-US/?user=Suchii%20_www.bewise.fr_WSS3 hide web part if permissions don't exist<p>Hi,</p> <p> </p> <p align=left>I've developped a WebControl able to hide unauthorized WebPart. You can download it from <a title="http://www.bewise.fr/download/toolbox/Bewise.SharePoint.RoleViewerManager.zip" href="http://www.bewise.fr/download/toolbox/Bewise.SharePoint.RoleViewerManager.zip">http://www.bewise.fr/download/toolbox/Bewise.SharePoint.RoleViewerManager.zip</a></p> <p align=left> </p> <p align=left>The .zip file contains a &quot;Read Me.txt&quot; explaining how to install it.</p> <p align=left> </p> <p align=left> </p> <p align=left>Laurent Cotton (Aka Suchii)</p> <p>MCTS / MCSD.NET / MCT</p> <p><a title="http://www.bewise.fr/" href="http://www.bewise.fr/"><u><font color="#0066cc">www.bewise.fr</font></u></a></p> <p>blog : <a title="mhtml:{C49AE5A1-5A1A-434D-B8A2-167B2BE7F3DB}mid://00000000/!x-usc:http://sharepoint.over-blog.fr/"><u><font color="#0066cc">http://sharepoint.over-blog.fr/</font></u></a></p> <p align=left><font face=Arial size=2></font> </p>Fri, 03 Aug 2007 07:19:26 Z2007-08-03T07:19:26Zhttp://social.msdn.microsoft.com/Forums/en-US/sharepointcustomization/thread/106ab22e-ded2-42d3-92f0-45b2ebbc54d2#33a20cb3-7a0c-4370-892c-ad04e8ec3a15http://social.msdn.microsoft.com/Forums/en-US/sharepointcustomization/thread/106ab22e-ded2-42d3-92f0-45b2ebbc54d2#33a20cb3-7a0c-4370-892c-ad04e8ec3a15JasonD240http://social.msdn.microsoft.com/Profile/en-US/?user=JasonD240WSS3 hide web part if permissions don't exist<p align=left><font face=Arial size=2>Hi Suchii,</font></p> <p align=left> </p> <p align=left>Thank you for the file. I attempted to use GACUtil to import the dll however it failed citing an unknown error. Any suggestions?</p> <p align=left> </p> <p align=left>Thanks,</p> <p align=left><br>Jason</p>Fri, 03 Aug 2007 15:10:14 Z2007-08-03T15:10:14Zhttp://social.msdn.microsoft.com/Forums/en-US/sharepointcustomization/thread/106ab22e-ded2-42d3-92f0-45b2ebbc54d2#6624bd06-42d1-435c-b95e-1222cd41a47ahttp://social.msdn.microsoft.com/Forums/en-US/sharepointcustomization/thread/106ab22e-ded2-42d3-92f0-45b2ebbc54d2#6624bd06-42d1-435c-b95e-1222cd41a47agrigbhttp://social.msdn.microsoft.com/Profile/en-US/?user=grigbWSS3 hide web part if permissions don't existHello Suchii,<br/><br/> <p class=MsoNormal style="margin:0cm 0cm 0pt"><span lang=EN-CA><span style="font-size:small;font-family:Times New Roman">I’ve tried to download your WebPart and I can not succeed.</span></span></p> <p class=MsoNormal style="margin:0cm 0cm 0pt"><span lang=EN-CA><span style="font-size:small;font-family:Times New Roman">The link is not more available. </span></span></p> <p class=MsoNormal style="margin:0cm 0cm 0pt"><span lang=EN-CA><span style="font-size:small;font-family:Times New Roman">Can you tell me where has been moved?</span></span></p> <p class=MsoNormal style="margin:0cm 0cm 0pt"><span lang=EN-CA><span style="font-size:small;font-family:Times New Roman">Thank you,<br/><br/></span></span></p> <p class=MsoNormal style="margin:0cm 0cm 0pt"><span lang=EN-CA><span style="font-size:small;font-family:Times New Roman">Gregoire</span></span></p>Fri, 03 Jul 2009 20:39:36 Z2009-07-03T20:40:12Zhttp://social.msdn.microsoft.com/Forums/en-US/sharepointcustomization/thread/106ab22e-ded2-42d3-92f0-45b2ebbc54d2#badc2272-cdb2-47ae-9fc8-72e2c449eadchttp://social.msdn.microsoft.com/Forums/en-US/sharepointcustomization/thread/106ab22e-ded2-42d3-92f0-45b2ebbc54d2#badc2272-cdb2-47ae-9fc8-72e2c449eadcKyle Schaefferhttp://social.msdn.microsoft.com/Profile/en-US/?user=Kyle%20SchaefferWSS3 hide web part if permissions don't existJason, as an alternative, you could also add a &quot;SPSecurityTrimmedControl&quot; around  a special web part zone on your page layout(s).  You'll want to create a web part zone on your page layouts that looks something like this:<br/><br/> <pre lang=x-aspx>&lt;SharePoint:SPSecurityTrimmedControl PermissionsString=&quot;ManagePermissions&quot; runat=&quot;server&quot;&gt; &lt;WebPartPages:WebPartZone id=&quot;zone1&quot; runat=&quot;server&quot; title=&quot;Top Zone&quot; /&gt; &lt;/SharePoint:SPSecurityTrimmedControl&gt;</pre> In this example, I have a web part zone inside the security-trimming control that only allows users with the &quot;ManagePermissions&quot; permission-level to see any web parts within that web part zone.  This is an OOTB fix that should be relatively easy to implement.<br/><br/>You can read more about the different permission levels you can use here:  <a href="http://codename-srini.blogspot.com/2009/04/spsecuritytrimmedcontrol-and.html">http://codename-srini.blogspot.com/2009/04/spsecuritytrimmedcontrol-and.html</a><br/><br/><br/>KyleMon, 06 Jul 2009 14:50:51 Z2009-07-06T14:50:51Z