JVCL Help:TJvTranslatorStrings

From Project JEDI Wiki
Jump to navigationJump to search
JEDI Visual Component Library Help

Search in JVCL Help

 
Search in all projects
 

Class Hierarchy

TJvTranslatorStrings
run\JvTranslator.pas


Summary

Stores translatable strings that are not part of a form or component, like variables etc.

run\JvTranslator.pas


Pascal

 run\JvTranslator.pas
 TJvTranslatorStrings = class(TJvComponent);


Description

  1. JVCLInfo

To be able to translate string variables not part of a class, you can use the TJvTranslatorStrings component. Drop it on a form (one per application is enough) and, at run-time, add the strings you want to translate by using the Add method. Note that the strings you add must be declared as global variables somewhere in your project.
Examplevar AString:string = 'This is a string';

...
// adding to list:
JvTranslatorStrings.Add('AString',AString);

// using:
ShowMessage(AString); // this will show the translated value of AString

                     // if it was included in the translation data
// loaded into a TJvTranslator instance

run\JvTranslator.pas


About

Navigation

run\JvTranslator.pas



Contribute to this help topic

This documentation wiki is based on the collaborative effort of Project JEDI users. Your edits are welcome in order to improve documentation quality: edit this page