DocumentUltimate translation problem
Problem reported by Daniel Guerriero - March 21 at 7:09 AM
Submitted
There are a few items that are not being translated, e.g.:

sidepanel.searchTab.anyWord
sidepanel.searchTab.wildCardMode
controlbar.find

What I tried:
  1. I tried editing "translation-es.json" file in the ".\App_GlobalResources\WebViewer\i18n" folder. When I change a single word in that file, the Spanish translation does not load anymore, everything is back to English. So I restored the original file.
  2. I tried adding a new file to that folder, named "translation-es-AR.json". On that file I was able to change existing phrases and it worked out just fine. But adding the missing items does not work at all, those phrases will still be in English.

4 Replies

Reply to Thread
0
Cem Alacayir Replied
Employee Post
> When I change a single word in that file, the Spanish translation does not load anymore 

The translation file is a JSON file so make sure you do not make a syntax error (e.g. missing double quotes, commas). Also make sure the file is saved with UTF-8 encoding (e.g. if you open it with Visual Studio it should keep the encoding but Notepad may not)

Are you sure you adding the new properties in spanish translation file in correct places like this:

{
  "controlbar": {
    ...
    "find": "Find",
    ...
    },
...
  "sidepanel": {
    ...
    "searchTab": {
      ...
      "anyWord": "Any word",
      "wildCardMode": "Wildcard search",
       ...
    }
  },
  ...
 }

Also note that "translation-es.json" file name should work if the file is correctly formatted (not needed to be "translation-es-AR.json" if it's not specific for es-AR)

0
Daniel Guerriero Replied
Thank you for your reply. I'm familiar with the JSON syntax. I also validated the JSON file with JSONLint, just in case, found a couple of errors in the original translation-es.json file (repeated items in a couple of collections). Fixing those errors won't help. ANY change I make to the translation-es.json file results in the Spanish language not loading.

 I also checked the file encoding. Notepad++ reports it's UTF-8 with boom.
0
Cem Alacayir Replied
Employee Post
Strange, did you use the latest translation files as specified in here ?
Also did you  try to explicitly set Language property:

documentViewer.Language = "es";
Normally it's detected automatically from Thread.CurrentThread.CurrentUICulture but you can force the language ("es" or "es-AR") by setting this property.
0
Daniel Guerriero Replied
The currentculture is properly set and the DocumentUltimateControl is shown in Spanish, unless I "touch" the "translation-es.json" file in the ".\App_GlobalResources\WebViewer\i18n" folder.

Reply to Thread