In this post we will discuss how to get all language packs installed in the SharePoint server using SharePoint 2010 object model.
Also you can check out my previous posts on:
To work with SharePoint object mode we need to refer Microsoft.SharePoint.dll assembly.
Below is the full code:
using (SPSite site = newSPSite("http://SiteURL"))
using (SPWeb web = site.RootWeb)
SPLanguageCollection languages = web.RegionalSettings.InstalledLanguages;
foreach (SPLanguage language in languages)
string displayName += language.DisplayName + " | ";
string lcid += language.LCID + " | ";