powerobjects: Language Localized Web Resources
When creating the resource files for each language there are few points that need to be remembered. In the web resource, you’ll need to include the numeric language code in the Name as well as specify the Language type in the Content settings. In this example, 1033 is English and 1036 is French. Also, make sure the key is the same in each file – example “Greeting.”
In this example, Visual Studio is being used to create the RESX files but under the hood, they are just XML files. The schema is a bit complex so if possible use a tool to create them rather than doing it manually.
In order to get a localized value from one of these files you can use the new “Xrm.Utility.getResourceString” method. The first parameter is the first part of the web resource Name including the prefix. The second is the key from the RESX file. The specific language is not defined anywhere. The result will come from the RESX file that matches the logged in user’s default language. If it doesn’t exist, it will fall back to the organization’s base language.
Once the setup is complete, you can bind scripts to form events as you normally would.
The resulting alert displays the value based on the logged in user’s language selection with is found under the user options.
When the language is set to English, the result comes from the English RESX file.
When the language is set to French, the result comes from the French RESX file.
There you have it! For more helpful Dynamics 365 tips and tricks check out our blog.
Happy Dynamics 365’ing!
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору.
|powerobjects: Searching Custom Web Resource Content||Blog bot||Dynamics CRM: Blogs||0||03.01.2018 20:12|
|crminthefield: Building Multi-Purpose Silverlight Web Resources in Dynamics CRM 2011||Blog bot||Dynamics CRM: Blogs||0||28.01.2012 02:16|
|Microsoft Dynamics CRM Team Blog: Web Resources Generated During Upgrades: Don't Ship Them!||Blog bot||Dynamics CRM: Blogs||0||08.08.2011 23:11|
|Inside Dynamics AX 4.0: The Web Framework||Blog bot||DAX Blogs||0||25.10.2007 03:04|
|Pokluda: Outbound web service (AIF)||Blog bot||DAX Blogs||0||28.10.2006 17:43|
|Опции темы||Поиск в этой теме|