Translating a form without tsilang component
Posted: Sun Nov 30, 2003 12:31 am
I wonder if it's possible to translate a form which has no tsiLang component on it. In my package I have to translate a dialog which is called from another package, so i cant just put a component on it (this package must be free of tsilang). But i can access the dialog form. So right now i'm using this:
With TFrmFindDlg(Form) Do
Begin
Caption := siLang.GetText('IDS_F_0');
btCancel.Caption := siLang.GetText('IDS_F_1');
...
What i am looking for is a way to load into tsilang component names and values, for example, for captions. Then, at runtime i would assign, let's say, _form_ property of tsilang, tsilang would scan the form for components with specified names and translate their captions. Is this somehow possible?
With TFrmFindDlg(Form) Do
Begin
Caption := siLang.GetText('IDS_F_0');
btCancel.Caption := siLang.GetText('IDS_F_1');
...
What i am looking for is a way to load into tsilang component names and values, for example, for captions. Then, at runtime i would assign, let's say, _form_ property of tsilang, tsilang would scan the form for components with specified names and translate their captions. Is this somehow possible?