Skip to content

Adding languages

newmans99 edited this page Aug 28, 2017 · 8 revisions

Instructions for adding languages

If you are adding a new language translation, you will need to update both the sample database tables for that language and the language strings for the user interface.

Sample Database Tables:

  1. Using Excel, open the ".\data\OrdersData.xls" file.
  2. On the Sector/Industry tabs, add a new column with the suffix "_XX" where XX = is the IETF language code for the language you are adding. Make sure that the XX is in upper case, e.g., "Sector_EN".
  3. Provide the translation for each row.
  4. On the Product/Company tabs, copy the "en" rows for each of the IDs and paste them to the end of the table. The language row should be in lower case, e.g., "en".
  5. Translate the Company/Product column values.
  6. On the Language tab, add a new row for the language that you just added. The language should be in lower case, e.g., "en".

Language Strings for UI

For Language Strings in the UI, you need to make the same language string modifications in three different locations. First the database (excel) table; Second, in a JSON file; and Finally, in a RESX file.

Database

  1. Using Excel, open the ".\data\OrdersData.xls" file.
  2. On the UI_Strings tab, copy the "StringID, StringValue, and BCP47" data from the "default" BCP47 rows.
  3. Paste those values to the bottom of the table.
  4. Provide the translation for all StringValue columns and update the BCP47 value based on the IETF language-region standard (language).

Resource Files: JSON

  1. Duplicate the ".\strings\MLjson_default.json" file and edit in your favorite text editor.
  2. Name the file with the lower case 2 digit language identifier. e.g., ".\strings\MLjson_ku.json" for Kurdish
  3. Update the metadata section by appending your name, date, and language identifier.
  4. For all name:value pairs, modify the second value (after the :, and inside the quotes) for each of the language strings.
  5. Validate that the document is a well formed json file, without extra quotes, colons, comma, etc... (see validator link below)
  6. Save the file.

Resource Files: RESX

  1. Duplicate the ".\strings\MLresx_default.resx" file and edit in your favorite text editor.
  2. Name the file with the lower case 2 digit language identifier. e.g., ".\strings\MLresx_ku.resx" for Kurdish
  3. Update the metadata section by appending your name, date, and language identifier.
  4. For all name:value pairs, modify the value for each of the language strings.
  5. Validate that the document is a well formed XML file, without extra quotes, colons, comma, etc... (see validator link below)
  6. Save the file.

Finishing up...

You can now add additional languages by repeating the steps above, or add REGIONs to this language, or if you are done with translations you can proceed to adding test users or straight to Test & Submit.

Resources: