How-to: Software Internationalization Done Right

Alex Lashkov
Yellow Universe
Published in
4 min readSep 24, 2018
Image credit: Unsplash

At 1Ci we provide technologically advanced automation solutions for businesses all over the world, including 1C:Enterprise development platform and 1C:Drive. Today our main products are translated into 12 different languages. In this piece, we will discuss issues which may occur when localizing software for international markets and give some advice on how to do this right.

Plan for internationalization from the beginning

Even if, for now, you are only developing the product for your home country, it is a good idea to keep some room for later expansion. This means using the English language for your source code, thus avoiding using complicated phrases that may make further translation harder.

First step: delocalization

To make the product truly international, in most cases you will have to delocalize it first. For example, at 1Ci we are working on enterprise-level business automation systems. This includes order management, sales and purchase, inventory and warehouse, accounting, and other important business processes.

Such processes are often designed and regulated in different ways in different countries. This means that before we can move to interface translation and the adoption of requirements from different regions, we first need to have a universal skeleton of the software. This skeleton will later build up the muscles of the content in different languages and features tailored to certain countries.

So, the first step is to cut off everything related to your home market, every feature, document, or phrase that only people in this country will understand. Once you have a framework to fill, move to the second stage and translate the product’s interface.

Focus on your strings

A significant part of the work connected to localization will revolve around strings. There are a number of rules to follow to avoid problems with strings during the internationalization of your software:

  • Never hard-code strings — this will look strange for users in most countries.
  • Extract, localize, and reinsert — it is better to externalize all user-visible strings, run them through translation and then put them back into the code.
  • Parametrization helps as well — you might want to change the order of strings, and parametrization will help do this.
  • Use Unicode — this format allows adding the information and symbols of different languages so that users can enter all types of data and the system will be able not only to display it but conduct the search as well.

Our platform 1C:Enterprise offers a number of functions that help in strings’ localization. One of them is NStr function which should be used instead of string literals. For example, the wrong way of localizing is to use something like:

ShowMessageBox(, “This operation requires the file system extension.”);

It is better to use a dedicated function:

ShowMessageBox(, NStr(“en=’This operation requires the file system extension.’”));

Sometimes you will have to deal with compound strings that may include parts dependent on different conditions. It is hard to localize them but the best practice is to use logically finished phrases. We have developed a function that helps in such cases, it is called StringFunctionsClientServer.SubstituteParametersInString.

It helps you to move from constructions such as:

ShortageMessage = “Not enough units of “ + ProductName + “ in warehouse “ + WarehouseName + “.”;

To much better ones like:

MessageText = NStr(“en=’Not enough units of %1 in warehouse %2.’”);

MessageText = StringFunctionsClientServer.SubstituteParametersInString(

MessageText, ProductName, WarehouseName);

In different languages, parameters may reside in different parts of the sentence which urges you to alter your source code to change strings elements, and makes translation harder. Using best practices and specialized functions will make your life as a developer much easier.

Don’t try to translate everything by yourself

Translation is a complicated and expensive process, so there is no need to do the whole job by yourself. A more reasonable thing to do here is to keep your mother tongue and English while using specialized translation tools to get other languages. We use Smartcat tool which helped us to add an additional 10+ languages to our applications.

Also, when designing enterprise-level or other complex systems it might be impossible to conduct proper internationalization for developers. In this case, it is better to seek help. For example, localized versions of our 1C:Enterprise platform always come from partners in a certain location.

We provide partners with a delocalized framework including customizable templates of different documents and files which could then be tailored to the needs of a certain company in a certain country.

Test everything

After you’ve finished with localization it is time to test it. The best thing is to test the functional and linguistic correctness of your interface and content for each target language. This is also the stage when you can fix display errors or formatting issues.

--

--