Quick Tip: How to Show Web parts Based on Security!

March 22nd, 2008 by coskunc

In most cases I see that SharePoint users using audiences to secure their web parts. But as most of you know this is really not a security feature. Audiences don't look at security, it will either hide or display the web part based on the audience settings.

If you really need to have Web Parts show based on security what you have to do is use the SecurityTrimmed control. All you have to do is open your default.aspx in your SharePoint Designer and add the following code snippet.

<Sharepoint:SPSecurityTrimmedControl runat="server" PermissionsString="ManageWeb">
 <WebPartPages:WebPartZone id="g_CC57BF5FF56740B099B0728E5C262566" runat="server" title="Secure Zone">
    </WebPartPages:WebPartZone>
    </SharePoint:SPSecurityTrimmedControl>

This will add a Web Part Zone named SecureZone to your default.aspx page which will allow you to add web parts that will only be displayed to Administrators. The way you decide who gets to see the Web parts is by changing the value of the PermissionsString. In this case it is set to ManageWeb which is what only administrators have. So the web parts that are added to this web part zone will one be displayed to administrators.

Some of the other Permission Strings are as follows:

ManagePermissions
ViewUsageData
ManageSubwebs
ManageWeb
AddAndCustomizePages
ApplyThemeAndBorder
ApplyStyleSheets
CreateGroups
BrowseDirectories
CreateSSCSite
ViewPages
EnumeratePermissions
BrowseUserInfo
ManageAlerts
UseRemoteAPIs
UseClientIntegration
Open
EditMyUserInfo

 

Quick Tip: How to Show Web parts Based on Security!

March 22nd, 2008 by coskunc

In most cases I see that SharePoint users using audiences to secure their web parts. But as most of you know this is really not a security feature. Audiences don't look at security, it will either hide or display the web part based on the audience settings.

If you really need to have Web Parts show based on security what you have to do is use the SecurityTrimmed control. All you have to do is open your default.aspx in your SharePoint Designer and add the following code snippet.

<Sharepoint:SPSecurityTrimmedControl runat="server" PermissionsString="ManageWeb">
 <WebPartPages:WebPartZone id="g_CC57BF5FF56740B099B0728E5C262566" runat="server" title="Secure Zone">
    </WebPartPages:WebPartZone>
    </SharePoint:SPSecurityTrimmedControl>

This will add a Web Part Zone named SecureZone to your default.aspx page which will allow you to add web parts that will only be displayed to Administrators. The way you decide who gets to see the Web parts is by changing the value of the PermissionsString. In this case it is set to ManageWeb which is what only administrators have. So the web parts that are added to this web part zone will one be displayed to administrators.

Some of the other Permission Strings are as follows:

ManagePermissions
ViewUsageData
ManageSubwebs
ManageWeb
AddAndCustomizePages
ApplyThemeAndBorder
ApplyStyleSheets
CreateGroups
BrowseDirectories
CreateSSCSite
ViewPages
EnumeratePermissions
BrowseUserInfo
ManageAlerts
UseRemoteAPIs
UseClientIntegration
Open
EditMyUserInfo

 

Silverlight BluePrint for SharePoint

March 10th, 2008 by coskunc

If you already haven't check out this site, it will give you a high level understanding of how you can integrate SharePoint with Silverlight. Now that the new version of silverlight is out I think it's time to integrate it into SharePoint.

http://www.ssblueprints.net/sharepoint/ 

This site has the following sample's code, video and documentation ready for download.

  1. Hello Silverlight Web Parts and the SilverlightPart
  2. Silverlight Navigation Controls
  3. Siverlight Social Networking Web Part
  4. Visual How-To center with Silverlight
  5. Picture Viewer sample
  6. Silverlight Custom Field Types 

Here are the sample screen shots of the silverlight controls

Custom Field Type Example 

Picture Viewer Sample

Silverlight Navigation Controls

Silverlight BluePrint for SharePoint

March 10th, 2008 by coskunc

If you already haven't check out this site, it will give you a high level understanding of how you can integrate SharePoint with Silverlight. Now that the new version of silverlight is out I think it's time to integrate it into SharePoint.

http://www.ssblueprints.net/sharepoint/ 

This site has the following sample's code, video and documentation ready for download.

  1. Hello Silverlight Web Parts and the SilverlightPart
  2. Silverlight Navigation Controls
  3. Siverlight Social Networking Web Part
  4. Visual How-To center with Silverlight
  5. Picture Viewer sample
  6. Silverlight Custom Field Types 

Here are the sample screen shots of the silverlight controls

Custom Field Type Example 

Picture Viewer Sample

Silverlight Navigation Controls

Microsoft SharePoint Online!

March 10th, 2008 by coskunc

Microsoft has announced today their Software as a Service SAAS platform is now available. Their platform includes SharePoint, Exchange, and Live Communications servers. They announced that CocaCola will be fully moving to this platform.

You can get more information on this by visiting: http://www.microsoft.com/online/sharepoint-online.mspx   

 

Microsoft SharePoint Online!

March 10th, 2008 by coskunc

Microsoft has announced today their Software as a Service SAAS platform is now available. Their platform includes SharePoint, Exchange, and Live Communications servers. They announced that CocaCola will be fully moving to this platform.

You can get more information on this by visiting: http://www.microsoft.com/online/sharepoint-online.mspx   

 

How delete webparts from a page using the browser (spcontnt.aspx)

November 14th, 2007 by coskunc

I'm not sure if you've run into this when you're developing custom webparts or adding 3rd party webparts to a page but this happens to me quite often, I get an error stating that the page cannot be displayed and I right of way I know it's a web part I added to the page that's causing the issue but I can't get to the page to delete the web part. I don't want to open SharePoint designer either, so how do you delete the web part with the browser if you can't accesss the page?

Use the following URL on any SharePoint site to see the webparts you have installed on your SharePoint page

/_layouts/spcontnt.aspx?&url=[your_page_url_goes_here] 

So if  the page you're having issues with looks like the following

http://www.yourserver.com/site1/default.aspx

To see the web parts on that page you would use the following link

http://www.yourserver.com/_layouts/spcontnt.aspx?&url=/site/default.aspx

When you get to that page you'll see that you can Close, Reset or Delete web parts on the page that you specified.

 

Hope this helps!

 

How delete webparts from a page using the browser (spcontnt.aspx)

November 14th, 2007 by coskunc

I'm not sure if you've run into this when you're developing custom webparts or adding 3rd party webparts to a page but this happens to me quite often, I get an error stating that the page cannot be displayed and I right of way I know it's a web part I added to the page that's causing the issue but I can't get to the page to delete the web part. I don't want to open SharePoint designer either, so how do you delete the web part with the browser if you can't accesss the page?

Use the following URL on any SharePoint site to see the webparts you have installed on your SharePoint page

/_layouts/spcontnt.aspx?&url=[your_page_url_goes_here] 

So if  the page you're having issues with looks like the following

http://www.yourserver.com/site1/default.aspx

To see the web parts on that page you would use the following link

http://www.yourserver.com/_layouts/spcontnt.aspx?&url=/site/default.aspx

When you get to that page you'll see that you can Close, Reset or Delete web parts on the page that you specified.

 

Hope this helps!

 

Presenting at a SharePoint event in Istanbul, Turkey

October 21st, 2007 by coskunc

I haven't had much time to blog the last 2 months due to my busy schedule but I'm hoping to start bloging again soon. But I wanted let the Turkish readers of sharepointblogs.com that I was invited to present at a SharePoint event held at Microsoft Turkey's Headquarters at Oct 24 2007.

 The event will be in Turkish and it will be around real life examples of what SharePoint can do for Turkish businesses. Hope to see you there!

 To sign-up for the event you can use the following link

http://go.microsoft.com/?linkid=7582846

 

 

Presenting at a SharePoint event in Istanbul, Turkey

October 21st, 2007 by coskunc

I haven't had much time to blog the last 2 months due to my busy schedule but I'm hoping to start bloging again soon. But I wanted let the Turkish readers of sharepointblogs.com that I was invited to present at a SharePoint event held at Microsoft Turkey's Headquarters at Oct 24 2007.

 The event will be in Turkish and it will be around real life examples of what SharePoint can do for Turkish businesses. Hope to see you there!

 To sign-up for the event you can use the following link

http://go.microsoft.com/?linkid=7582846