January 2012 - SharePoint Tips

  • Watch for unlimited amount of versions

    Mattias Karlsson -Expert in Residence SharePoint offers versioning of documents and items and for document libraries we are able to have both minor and major versions. Each version of a document, both minor and major version is stored in the content database as a full version. This means that a 10MB PowerPoint presentation that has 10 versions is using 100 MB in your content database. Combine that with a number of draft versions and a lot of documents...
  • Find more information about your Web Applications

    Niklas Goude -Expert in Residence A simple and effective way of finding information about your Web Applications is by using the Get-SPWebApplication cmdlet. Simply enter the cmdlet name to list all Web Applications in your farm. PS > Get-SPWebApplication If you want to display specific properties, use the Select-Object cmdlet. PS > Get-SPWebApplication | Select-Object Name , Url ReTweet this Tip!
  • Add Text Field to a List

    You can use Windows PowerShell to add Text fields to a List in SharePoint 2010. Simply use the Add() method available on a fieldcollection. The example below demonstrates how to add a Text field to the Tasks list, set a Description and set the field as required. Note that the Add() method allows us to specify the Fields Name, the Type of Field and a Boolean value that determines if the field should be required. PS > $spWeb = Get-SPWeb http : /...
  • Add UI Culture In PowerShell

    You can add supported UI Cultures to a SharePoint 2010 Site using Windows PowerShell. First, you can retrieve a specific Web site: PS > $spWeb = Get-SPWeb http : // SP01.powershell.nu Next, set the IsMultilingual property to true: PS > $spWeb . IsMultilingual = $true PS > $spWeb . Update () Next, you can retrieve the Regional Settings that are used on the Server: PS > $spReg = New-Object Microsoft.SharePoint.SPRegionalSettings $spWeb Next...
  • Update Web Parts

    You can use Windows PowerShell when updating Web Parts on a SharePoint 2010 Web site. First, you can retrieve a specific Web site: PS > $spWeb = Get-SPWeb http : // SP01.powershell.nu Next, retrieve the Site page that contains the Web Part and check it out: PS > $sitePages = $spWeb . GetFolder ( "SitePages" ) PS > $homeASPX = $sitePages . Files | >> Where-Object { $_ . Name -eq "Home.aspx" } PS > $homeASPX . CheckOut...
  • Add Custom Groups to the QuickLaunch

    You can add Custom groups in SharePoint 2010 to the QuickLaunch using PowerShell. This is a scenario that you might encounter if you’re creating sites using code. To add Custom created groups to the QuickLaunch, you can use the spWeb property bag directly as shown below. First, you can retrieve a specific Web site: PS > $spWeb = Get-SPWeb “ http : // SP01.powershell.nu ” Next, get the group that you want to associate: PS >...
  • Associating Custom Groups

    You can associate Custom Groups in SharePoint 2010 as Visitor Group, Member Group or Owner Group. This is a scenario that you might encounter if you’re creating Web sites using code. To associate custom-created groups, you can use the spWeb property bag directly as shown below. First, you can retrieve a specific Web site: PS > $spWeb = Get-SPWeb “ http : // SP01.powershell.nu ” Next, get the group that you want to associate: PS...
  • Add a Text Field to a List

    You can use Windows PowerShell to add Text fields to a List in SharePoint 2010. Simply use the Add() method available on a fieldcollection. The example below demonstrates how to add a Text field to the Tasks list, set a Description and set the field as required. Note that the Add() method allows us to specify the Fields Name, the Type of Field and a Boolean value that determines if the field should be required. PS > $spWeb = Get-SPWeb http : /...
  • Add UI Culture

    You can add supported UI Cultures to a SharePoint 2010 Site using Windows PowerShell. First, you can retrieve a specific Web site: PS > $spWeb = Get-SPWeb http : // SP01.powershell.nu Next, set the IsMultilingual property to true: PS > $spWeb . IsMultilingual = $true PS > $spWeb . Update () Next, you can retrieve the Regional Settings that are used on the Server: PS > $spReg = New-Object Microsoft.SharePoint.SPRegionalSettings $spWeb Next...
  • Updating Web Parts

    You can use Windows PowerShell when updating Web Parts on a SharePoint 2010 Web site. First, you can retrieve a specific Web site: PS > $spWeb = Get-SPWeb http : // SP01.powershell.nu Next, retrieve the Site page that contains the Web Part and check it out: PS > $sitePages = $spWeb . GetFolder ( "SitePages" ) PS > $homeASPX = $sitePages . Files | >> Where-Object { $_ . Name -eq "Home.aspx" } PS > $homeASPX . CheckOut...
  • Adding a Custom Group to the QuickLaunch

    You can add Custom groups in SharePoint 2010 to the QuickLaunch using PowerShell. This is a scenario that you might encounter if you’re creating sites using code. To add Custom created groups to the QuickLaunch, you can use the spWeb property bag directly as shown below. First, you can retrieve a specific Web site: PS > $spWeb = Get-SPWeb “ http : // SP01.powershell.nu ” Next, get the group that you want to associate: PS >...
  • Associate Custom Groups

    You can associate Custom Groups in SharePoint 2010 as Visitor Group, Member Group or Owner Group. This is a scenario that you might encounter if you’re creating Web sites using code. To associate custom-created groups, you can use the spWeb property bag directly as shown below. First, you can retrieve a specific Web site: PS > $spWeb = Get-SPWeb “ http : // SP01.powershell.nu ” Next, get the group that you want to associate: PS...
  • Find info about Farm configurations

    Niklas Goude -Expert in Residence You can use the Get-SPFarmConfig cmdlet to retrieve global settings for the local farm. The cmdlet returns information for items that are not on the SPFarm Object. PS > Get-SPFarmConfig WorkflowBatchSize : 100 WorkflowPostponeThreshold : 15 WorkflowEventDeliveryTimeout : 5 DataFormWebPartAutoRefreshEnabled : True ASPScriptOptimizationEnabled : True ReTweet this Tip!
  • Restrict a creation of new content in site collections

    Mattias Karlsson -Expert in Residence If a site collection is growing to large or you for other reasons want to prevent users from adding new content, you can set a site collection lock on the site so that only existing content can be modified. This can be done either using PowerShell or from Central Administration. In SharePoint 2010 you find this setting in Central Administration by going to Application Management and Site Collection, quotas and...
  • Set Web Applications outgoing email addresses

    Niklas Goude -Expert in Residence You can use PowerShell to set a Web Applications outgoing email address and SMTP Server. Simply use the Set-SPWebApplication cmdlet. PS > Set-SPWebApplication -Identity http : // SP01 ` >> -OutgoingEmailAddress mail @ domain.com ` >> -SMTPServer ex01.domain.com ReTweet this Tip!
1 2 Next >
Idera SharePoint Reviews SMBology, Inc. Rackspace Hosting Sponsored by Idera and SharePoint Reviews and SMBology and EPCGroup.net
Copyright 2011 SecretsOfSharePoint.com. All rights reserved.