Soluling home   Document home

Delphi

Initial language

A multilingual application contains support for several languages. You can either implement a multilingual application that can choose the language it uses when it starts, or you can go even further by adding support for runtime language change. In the first method, the application starts on the language that either OS or the application code selects it, but you can not change it afterward. To run such a multilingual application in a different language, you have to stop it, modify the applications and/or operating system settings, and start again.

Let's have an example. We have an English application, Application.exe, and its resource files (called satellite assembly files in .NET) in French, German and Japanese. The following table contains the application files.

Description .NET Delphi Visual C++
Original English application file created by the development tool Application.exe Application.exe Application.exe
German satellite assembly or resource file created by Soluling de\Application.​resources.dll Application.DE Application.DEU
French satellite assembly or resource file created by Soluling fr\Application.​resources.dll Application.FR Application.FRA
Japanese satellite assembly or resource file created by Soluling ja\Application.​resources.dll Application.JP Application.JPA

This makes the application to support four languages. If you start the application on French Windows, the application will load the French resources (fr\Application.resources.dll, Application.FR or Application.FRA), and the application will initially show up in French.

In order to run the application in German, you need to change the settings, close it, and finally start again.

The way you control what the initial language is, depends on your development tool.

If you want to avoid restarting between language changes you have to implement runtime language change.