After scanning and updating your files only one final step is required.
Add the lines below in the appropiate place in you programme, usualy in the programmes main file before the creation of any windows etc.
IncludeFile "Locale.pbi"
Locale::AppLanguage = "English"
;Locale::AppLanguage = "Deutsch"
;Locale::AppLanguage = "Français"
;Locale::AppLanguage = "Italiano"
Locale::Initialise()
The IncludeFile line simply adds the included locale module to your application.
Only one of the next four lines is required. This sets the default language for the application. This can of course be set in a preferences file or use some other method to set the language of your application.
The following is an example of an application which checks a preferences file and sets the language on the preferred setting. If no preference is found then the user is prompted to select a language before application start which is then saved into the preference file for future runs of the programme.
;Read This applications preferences
APP::ReadPreferences("LT.ini")
IncludeFile "Locale.pbi"
;Select Language For This Programme If Not set
If App::Language = "" ;No Language Found
Locale::AppLanguage = "English" ;Default
Locale::Initialise() ;Set texts to default language needed for select language dialogue
Locale::SelectLanguage() ;Show select language dialogue
App::Language = Locale::AppLanguage ;Store the selected language in preferences
App::Writepreferences("LT.ini")
Else
Locale::AppLanguage = App::Language ;
EndIf
Locale::Initialise()