When we create a site collection or site we could be able to see an option for selecting the language.
Go to Central Administration => Application Management=> Site Collections => Create Site Collections =>Select a language.
Go to SharePoint site => Site Actions => New Site => Select Language.
This selection of language becomes the default language for the site or site collection.
The default language can be determined by using the SharePoint 2010 object model.
UICulture Property: SPweb.UICulture property is used to get a CultureInfo object that represents to the default language for the Web site.
Namespace: Microsoft.SharePoint Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Open Visual Studio 2010.
Go to File => New => Project.
Select Console Application template from the installed templates.
Enter the Name and click Ok.
Add the following assembly. -Microsoft.SharePoint.dll
Add the following namespace. -Using Microsoft.SharePoint ; -Using System.Globalization;
Program.cs looks like the following.
Build the solution.
Go to Start => All Programs => Microsoft SharePoint 2010 products => SharePoint 2010 Management Shell.
Run as an administrator.
Run the following script to get the Default language.