Wednesday, October 26, 2011

Enable Multilingual User Interface (MUI) in SharePoint 2010

Creating multilingual SharePoint 2010 site is extremely useful when working for global SharePoint deployments. It allows a logged on user to change the language to one of the supported alternate languages configured. All the standard SharePoint user interface elements are translated with this feature. Like:
  •     Ribbons
  •     Site Settings Page
  •     Site Actions Menus
  •     Lists and Site Column headers
  •     Quick Launch Menu
  •     Certain Messages displayed in out of the box webparts
Please note: when you switch the language via MUI selector it only translates UI elements, content in the site is not translated. You can use Variations to change the content. More info: http://technet.microsoft.com/en-us/library/cc262055.aspx#Section4

Follow these steps to enable multilingual sharepoint 2010 sites
Step 1: Download and Install the appropriate Language pack
Multilingual support for SharePoint 2010 is provided via language packs. Download and install the desired SharePoint Foudation & SharePoint Server Language Packs.

Important: For SharePoint Foundation 2010, You can just install SharePoint Foundation 2010 language pack alone. But for SharePoint Server 2010, both SharePoint Foundation language packs & SharePoint Server language packs must be installed.

For Multilingual User Interface, a corresponding language pack has to be installed for every language. For instance, To enable the "Hindi" language interface in ShaerPoint, you have to download & Install the Hindi language pack.

SharePoint 2010 Language Packs

1. Download the Language pack for appropriate language:
SharePoint 2010 Language Packs download

2. Install the downloaded Language packs:
 multilingual in sharepoint 2010
3. Run the Products and Technologies configuration wizard after the installation:
4. You can verify the installed language packs by navigating to:  Central Administration >> Upgrade and Migration >> Check product and patch installation status. Here you can get the list of installed language packs.
enable multilingual sharepoint 2010

Step 2: Enable the Language packs
These steps has to be execute the on every site collection where you need to activate SharePoint 2010 multilingual user interface.

1. Open the SharePoint site collection, Go to the ‘Site Settings’ via the ‘Site Action’ menu

2. Under the Site Administration select "Language Settings". “Language Settings” won't appear under Site Administration section in Site Settings page until language packs are installed.
 sharepoint 2010 multilanguage howto
3. Choose the languages that should be available for end-users and Click Ok to Save the setting.
 multilingual support for sharepoint 2010
4. Now the languages are available via the ‘Welcome Menu’ in Top Right, an option added "Select Display Language".
enable multilingual sharepoint 20105. Select the language to view the site in that language. SharePoint 2010 multilingual interface for Site settings page should look like:
multilingual support for sharepoint 2010
Technet reference: http://technet.microsoft.com/en-us/library/ff805062.aspx

Update: In SharePoint 2013, you won't see the options to switch languages from site settings Menu. SharePoint 2013 works based on browser settings. So Go to Internet explorer's options to change the Language!

You might also like:
SharePoint Usage Reports
Usage reports, collaboration and audit for SharePoint.
Document SharePoint Farm
Automatically generate SharePoint documentation.
*Sponsored


Thursday, October 20, 2011

Restore Deleted Site Collection or Subsite from SharePoint 2010 - SP1 or Later

In SharePoint 2007, There was a wonderful tool from Codeplex: Site Delete Capture http://governance.codeplex.com/ to back up sites automatically when they gets deleted, So that we can restore a deleted site collection in SharePoint 2007.

In SharePoint 2010 SP1, Microsoft added instinct support to capture/restore Site collections or Sub-sites on the event of deletion.

So, when your sub-sites gets deleted, navigate to Site collection recycle bin and you can find the deleted sites, you will be able to restore from there.
sharepoint 2010 recover deleted site
SharePoint 2010 recover deleted site


What do to when the Site collection itself deleted?
How to restore deleted site in SharePoint 2010? To recover deleted site collection in SharePoint 2010, You can use these three cmdlets:

  1. Get-SPDeletedSite - Displays list of sites deleted.
  2. Restore-SPDeletedSite - Restore a deleted site
  3. Remove-SPDeletedSite - To permanently remove the deleted site collection.
sharepoint 2010 recover deleted site collection
SharePoint 2010 sp1 restore deleted site collection

Permanently Remove the Deleted sites to Recover Disk Space: 
After a while, many sites collections were deleted in a clean-up activity. So decided to permanently delete all deleted site collections from recycle bin. Here is the PowerShell script:

Get-SPDeletedSite -webapplication http://sharepoint.company.com | Remove-SPDeletedSite


You might also like:
SharePoint Usage Reports
Usage reports, collaboration and audit for SharePoint.
Document SharePoint Farm
Automatically generate SharePoint documentation.
*Sponsored


Saturday, October 15, 2011

Update Wrong Old URL in SharePoint Alerts on SharePoint Migration or URL Change

After upgrading from MOSS 2007 to SharePoint 2010, existing SharePoint alerts stopped working and only newly created alerts worked!!! We got to Fix Alerts after SharePoint migration, manually.

Tried these trial and errors:
  • Tried editing existing alerts, just changed its Name, It worked!
  • Tried Turning Individual Alert ON and OFF - Yes, Worked! but I've some 1000+ alerts for a Large web application. How about PowerShell?

$SPSite= Get-SPSite "http://mySharePoint.com/sites/alerts/"

foreach ($spweb in $SPSite.AllWebs)
    {
        foreach($alert in $spweb.Alerts)
            {
                $OriginalTitle = $alert.Title
                $alert.Title = "UPDATE: $OriginalTitle"
                $alert.Update()

                $alert.Title = $OriginalTitle
                $alert.Update()
                Write-Host "Updated Alert" $alert.Title "in"$spweb.url

            }
    }
But wait, the problem is not fully solved. From the Alert mails fired from the alerts created in MOSS 2007, URLs in the Alert mail is still pointing to OLD URL!
sharepoint 2010 email alerts wrong url

Fix SharePoint alerts wrong URL Issue:
Again, Powershell is a life saver. Use this script to Fix the wrong URLs in alerts and to fix the issue of "Old Alerts are not firing"

$SPSiteURL = "http://NewSharePoint.com/sites/alerts" #Site Collection Url 
$oldrooturl = "https://OldSharePoint.crescent.com" # Old URL of the webapplication
$rooturl = "http://NewSharePoint.com" # New URl for the new webapplication

$SPsite = Get-SPSite -Identity $SPSiteURL 
$SPwebs = $SPsite.AllWebs 

$updated = 0

foreach ($web in $SPwebs) #Get All the sub sites
{
  $alerts = $web.alerts  # Get All Alerts

  if ($alerts.count -ne 0)
   {    
   Write-Host -foregroundcolor green "Number of Alerts in: "$web.url ":" $alerts.count
   
    foreach ($alert in $alerts)
    {
  #preserve & Change the the Alert frequency, so that the so the datarow inside is touched by SharePoint API. 
  $Status = $alert.Status 
                $Frequency = $alert.AlertFrequency
                    if($Frequency -eq [Microsoft.SharePoint.SPAlertFrequency]::Immediate)
                     { 
                         $alert.AlertFrequency = [Microsoft.SharePoint.SPAlertFrequency]::Weekly 
                     } 
                    else
                      { 
                         $alert.AlertFrequency = [Microsoft.SharePoint.SPAlertFrequency]::Immediate 
                      } 
   
   $title = $alert.title
          $alert.title = "UPDATED" + $title
          $alert.Status = [Microsoft.SharePoint.SPAlertStatus]::Off 

             $alert.Update()  #Update the modified values
             
       if ($alert.Properties -ne $null)
        {
          if ($alert.Properties["siteurl"] -ne $null -and $alert.Properties["siteurl"].Contains($oldrooturl))
           {
             $alert.Properties["siteurl"] = $alert.Properties["siteurl"].Replace($oldrooturl, $rooturl)
           }
           if ($alert.Properties["mobileurl"] -ne $null -and $alert.Properties["mobileurl"].Contains($oldrooturl))
           {
             $alert.Properties["mobileurl"] = $alert.Properties["mobileurl"].Replace($oldrooturl, $rooturl)
           }

          $updated++

         }


 #Reset the Values of alert, back to their original
      $alert.title = $title
             $alert.AlertFrequency = $Frequency 
      $alert.Status = $Status 
             $alert.Update()    

  write-host "Alert updated: " $title
        #$alert.Properties

    }
    Write-Host "Number of alerts updated: " $updated
  }
}

Not only during Migration, But this will help during changing the SharePoint URL also! Once you get a list of locations, Just Turn-Off and Turn-On the Incoming E-Mails settings of the Library.

Microsoft KB Addressing this issue: http://support.microsoft.com/kb/936760

In MOSS 2007, after moving to new URL you can simply run the "stsadm -o updatealert" command to update the alert mail's URLs.

Lately, Microsoft released a Custom Cmd-let Invoke-AlertFixup which is equivalent of UpdateAlert operation. here is the link: http://technet.microsoft.com/en-us/library/cc508847.aspx

You might also like:
SharePoint Usage Reports
Usage reports, collaboration and audit for SharePoint.
Document SharePoint Farm
Automatically generate SharePoint documentation.
*Sponsored


Wednesday, October 12, 2011

User Profile Sync not importing AD Users - The management agent "AD-Connection-Name" failed on run profile "DS_FULLIMPORT" because of connectivity issues.

In a SharePoint 2010 installation that I recently worked, got failures in the log when trying o perform User Profile Synchronization. While debugging, in the Event log, There was a clue:

The management agent "SharePoint-MyCompany" failed on run profile "DS_FULLIMPORT" because of connectivity issues.
User Profile Sync not importing AD objects
I went through the checklists, guidelines and what I've done, and everyhing looks Perfect, But I had missed one step: Granting Replicate Directory Changes permission on the domain.

For the profile synchronization to work, our service account which is being used by UPS should have the “Replicate Directory Changes” permission on a domain. This rights for query changes in the directory. This permission does not allow an account to make any changes in the directory. Refer: http://technet.microsoft.com/en-us/library/hh296982.aspx#RDCdomain

So, Here are the steps to fix:
  1. Open the Active Directory Users and Computers snap-in
  2. On the View menu, click Advanced Features.
  3. Right-click the domain object, such as “company.com”, and then click Properties.
  4. On the Security tab, if the desired user account is not listed, click Add; if the desired user account is listed, proceed to step 7.
  5. In the Select Users, Computers, or Groups dialog box, select the desired user account, and then click Add.
  6. Click OK to return to the Properties dialog box.
  7. Click the desired user account.
  8. Click to select the "Replicating Directory Changes" check box from the list.
  9. Click Apply, and then click OK.
After that, started UPS full import again, and the issue got fixed!
 The management agent “SharePoint-MyCompany” failed on run profile “DS_FULLIMPORT” because of connectivity issues.

You might also like:
SharePoint Usage Reports
Usage reports, collaboration and audit for SharePoint.
Document SharePoint Farm
Automatically generate SharePoint documentation.
*Sponsored


Monday, October 3, 2011

Extract and Download All Installed Solution Packages (WSP Files) in SharePoint

There were many solution packages installed in my current SharePoint environment. During a server replacement we noticed that the WSP file for a particular solution is missing in TFS! (Our version control repository!)

Thankfully, we have a solution to this issue using: http://archive.msdn.microsoft.com/SPSolutionExtractor. To extract and download all installed solution WSP files, Just execute:  
SharePointFarmSolutionExtractor.exe -extractAll c:\SharePointSolutions

which will extract all WSP files from installed solutions!
Download All Installed Solution Packages (WSP Files) in SharePoint

Download deployed solutions(WSP) from central admin with PowerShell in SharePoint 2010: 

$dirName = "c:\Solutions"
foreach ($solution in Get-SPSolution)
{
    $id = $Solution.SolutionID
    $title = $Solution.Name
    $filename = $Solution.SolutionFile.Name
    $solution.SolutionFile.SaveAs("$dirName\$filename")
}
 
If you want to download a particular solution, use this PowerShell Script:
$farm = Get-SpFarm
$SolutionFile = $farm.Solutions.Item("SolutionName.wsp").SolutionFile
$SolutionFile.SaveAs("D:\SolutionFile.wsp")

Download Installed Solution Packages in SharePoint 2007:
[void][reflection.assembly]::LoadWithPartialName("Microsoft.SharePoint")

#Get Farm object
[Microsoft.SharePoint.Administration.SPFarm]$farm = [Microsoft.SharePoint.Administration.SPFarm]::get_Local()

#Create a Directory for Solutions
if ( (Test-Path -path "c:\Solutions\") -ne $True)
{
 New-Item c:\Solutions\ -type directory
}


$dirName = "c:\Solutions"

foreach ($solution in $farm.Solutions)
{   
    Write-Host "Downloading solution $($Solution.Name)"
    $filename = $Solution.SolutionFile.Name
    $solution.SolutionFile.SaveAs("$dirName\$filename")
}  



You might also like:
SharePoint Usage Reports
Usage reports, collaboration and audit for SharePoint.
Document SharePoint Farm
Automatically generate SharePoint documentation.
*Sponsored


Sunday, October 2, 2011

How to Embed and Integrate Youtube Videos in SharePoint Content Editor Web Part

Its a frequently asked question to me, guys asking: "I need to add YouTube videos in my SharePoint  site". In fact it is very simple to implement. So I’m going to walk-through on how to embed YouTube videos in SharePoint, just using content editor web part.


1.   Go to YouTube.com and get to the page where your desired video resides. Right click on the video and choose "copy embed html", it should be something like this


<object style="height: 390px; width: 640px"><param name="movie" value="http://www.youtube.com/v/TE9TpraPlrE?version=3"><param name="allowFullScreen" value="true"><param name="allowScriptAccess" value="always"><embed src="http://www.youtube.com/v/TE9TpraPlrE?version=3" type="application/x-shockwave-flash" allowfullscreen="true" allowScriptAccess="always" width="640" height="360"></object>

2.   Create a Web Part Page or modify an existing page thats going to display the video content and add a Content editor webpart into it

3.   Modify the content editor webpart and paste the embed html code by clicking "Source Editor"

4.   Click Ok, and publish the page. Here is the result:


You might also like:
SharePoint Usage Reports
Usage reports, collaboration and audit for SharePoint.
Document SharePoint Farm
Automatically generate SharePoint documentation.
*Sponsored


You might also like:

Related Posts Plugin for WordPress, Blogger...