Search code examples
sharepoint-2010localizationinfopath2010

Infopath 2010 get culture from hosting environment


I am looking into localizing the labels of an InfoPath 2010 form with code-behind that will be hosted in SharePoint as a browser form and get the current culture (based on the SharePoint variations) programatically in the InfoPath form. How do I do this?


Solution

  • You can get culture by using the SPWeb's Locale Property. You will have to reference the Microsoft.SharePoint.dll in your InfoPath project to get this to work.