PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK
  • Overview
  • Choosing the languages supported by the project and the analysis
  • Languages supported by the project
  • Languages supported by the analysis
  • Languages supported by the different project elements
  • Translating the interface into several languages
  • Selected translation mode
  • Languages that use a specific character set
  • Translating specific pages
  • Translating messages found in the WLanguage code
  • Choosing the language by programming
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
7. Multilingual sites in practice
Previous pageTable of contentsNext page
Overview
A multilingual site can be distributed in several languages. The different languages of the site will be taken into account during the different development steps.
The main steps for developing a multilingual site are as follows:
  1. Choosing the languages supported by the project and the analysis.
  2. Entering the different project elements (pages, code, ...) in the different project languages.
  3. Defining the project language by programming.
  4. Managing specific character sets in the data files.
  5. Creating the library and the setup program.
Notes:
  • If the operating system supports several languages (Hebrew, Arabic, Greek, ...), the corresponding character set will be automatically used when typing translations in these languages.
  • If your site is a multilingual site, this feature must also be managed in the pages of user groupware and in the pages for automatic management of HFSQL errors. See the online help for more details.
  • The management of Unicode is available in the HFSQL data files and in the controls of pages.
Choosing the languages supported by the project and the analysis

Languages supported by the project

The different languages supported by the project are defined in the project description:
  1. On the "Project" pane, in the "Project" group, click "Description". The description window of the project is displayed.
  2. In the "Languages" tab, you have the ability to add or delete the languages supported by the project.
The selected languages will be proposed for all multilingual resources that can be translated (captions of controls, menu options, help message associated with a control, ...).
When modifying the project languages, the modifications will be automatically taken into account:
  • for each new element or object created in the WEBDEV editor,
  • all each element or object opened in the WEBDEV editor.
The main language corresponds to the language used by default at run time.
Linguistic options
The "Languages" tab of project description is also used to define the options specific to a language: number, currency, date, ...
The parameters used by default are the ones defined in the linguistic options of Windows (accessible from the Windows control panel).
When creating an edit control or a table column that displays numeric data (number, currency, date, time, duration, ...), the input mask used will be the mask defined in the language options of project. This option is available in the pages.
At run time, when an edit control or a table column has a mask "Defined by the project", the input mask and/or the display mask will automatically adapt according to the options selected in the project for the language displayed at run time.
Note: The linguistic options are also used to define the writing direction and the character set used ("various" option).

Languages supported by the analysis

If your project is using an analysis, the choice of languages supported by the analysis is performed in the data model editor. Indeed, the same analysis can be shared among different projects that do not propose the same languages. Therefore, the number of languages defined for the analysis can be greater than the one defined for the project.
To configure the languages supported by the analysis:
  1. Display the analysis of your project in the editor.
  2. Display the description window of the analysis: on the "Analysis" pane, in the "Current element" group, click "Description".
  3. Select the "International" tab.
The different languages configured in the analysis will be proposed:
  • when configuring the shared information of items. The description of the controls linked to items (options, captions, ...) can be typed in the different languages supported by the analysis. When generating a "full application RAD" or a page RAD, this information is automatically taken into account by all the languages common to the analysis and to the project.
  • for the information printed in the program documentation (notes of data file or item).

Languages supported by the different project elements

By default, the different project elements (pages, reports, code, classes, ...) support the same languages as the project where they have been were created.
In some cases, an element may support more languages than the project (when the element is shared between several projects that support different languages for example).
Translating the interface into several languages
When the languages supported by the project have been selected, the information displayed by the site must be translated into these different languages.
To translate the interface into several languages, several elements must be taken into account:
  • The selected translation mode.
  • The supported languages.
  • The use of specific pages (user groupware, automatic management of HFSQL errors).
  • The messages displayed by programming.

Selected translation mode

WEBDEV proposes several translation modes:
  • Automatic translation of interfaces via a specific translation tool, found on the development computer. This translation is performed in the WEBDEV editor.
  • Check out all the messages to translate via WDMSG and check them back in after translation.
Translating interfaces
For each object, several multilingual areas are displayed in the description window. These multilingual areas allow you to enter information in the different languages supported by the project.
To translate this information from WEBDEV:
  1. Display the WEBDEV options for configuring the translation options of software used: on the "Home" pane, in the "Environment" group, expand "Options" and select "General options of WEBDEV".
  2. In the "Translation" tab, choose:
    • the default translation tool (as well as the transmission mode for the text to translate and for the translated text).
    • the source and destination languages for the translation.
  3. If a translation tool is specified, a "Translate" button will be displayed in each element containing information to translate. This button is used to translate the selected text via the specified translation tool.
  4. To perform the translation, all you have to do is select the text to translate and click the "Translate" button.
Checking out and checking in the information to translate
WDMSG is used to check out all the project messages (captions of controls, ...) and check them back in after translation.
Contact PC SOFT Sales Department for more details about the conditions for using this product.

Languages that use a specific character set

If your site supports languages that use specific character sets (Greek, Russian, ...), you must enter the translation of the different messages by using these specific character sets.
WEBDEV allows you to automatically manage the use of specific character sets in the editor.
Indeed, as soon as the edit cursor of the mouse is located in an input area of a language that uses a specific character set, the corresponding input language (character set used by the keyboard) is automatically displayed.
Therefore, if a caption is entered in the Russian section of the caption description, the keyboard will automatically switch to the Russian character set.
Reminder: To use specific character sets, the files corresponding to the requested character sets must be installed in the regional options of Windows (control panel).

Translating specific pages

Management of HFSQL errors
By default, the pages for managing the HFSQL errors are supplied in English and in French. To translate them into another language, you must:
  1. Include the default error pages in your project. These pages are supplied as example in \Programs\Data\Preset pages\HFSQL - Automatic help pages.
  2. Customize the management of errors to use the HFSQL pages for error management (HOnError).
  3. Translate the different messages (see previous paragraph).
User groupware
By default, the user groupware is supplied in English and in French.
To translate a site that uses the user groupware, you must choose the "Custom" mode when the user groupware is included in your site. Reminder: To configure the user groupware, on the "Project" pane, in the "Project" group, click "User groupware".
The different pages of user groupware will be included in your project.
Then, all you have to do is translate these pages.
Note: Uncheck "AutoRun" if necessary: this allows you to display a page for language selection before starting the login page.

Translating messages found in the WLanguage code

In your code, several WLanguage functions allow you to communicate with users via character strings. These messages must also be translated into the different languages of your site.
To translate a character string typed in the code editor:
  1. Select the character string to translate.
  2. Select "Translate" from the popup menu of the selection. The window for translating messages is displayed.
  3. Type the translation and validate. The code line is displayed in the code editor:
    • The flag indicates that translations exist for this character string. Click this flag to display the translation window.
    • The number (2 in our example) indicates the number of translations typed for this character string.
Note: To transform all the messages found in your code into multilingual messages, on the "Code" pane, in the "Languages" group, expand "Translate the strings" and select "Convert the simple strings into multilingual messages".
Choosing the language by programming
A multilingual site is an application that can be distributed in several languages. The user will be able to choose the runtime language of application. You can for example:
  • ask for the runtime language during the first application start.
  • implement an option (menu option or button for example) allowing the user to change the current language of the application.
Previous pageTable of contentsNext page
Minimum version required
  • Version 24
Comments
Click [Add] to post a comment