SiComponents Home Page SiComponents Forums
Here you will be able to get help and share your experience
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Problem with Default Translation of Constants

 
Post new topic   Reply to topic    SiComponents Forums Forum Index -> TsiLang Components Suite
View previous topic :: View next topic  
Author Message
rallef



Joined: 19 Jun 2010
Posts: 1

PostPosted: Wed Jul 28, 2010 12:26 am    Post subject: Problem with Default Translation of Constants Reply with quote

Hello,

I'll try to explain my problem:

while starting the application I look if there is a .sib file. If it's there it will be loaded. If it's not there I'll go on without loading..., so the default language stored will be the one that is valid.

I put some strings to constants (example: 'Would you like to save the changes?") to a unit without a form. So, if there is no .sib file to load, the constant is initialized with an empty string because there is no "ChangeLanguage" event that will read the default string stored with the .frm.

Is there any function to load just the default values for the constants (var strings) stored in the .frm's without changing the language forward and back to get an "ChangeLanguage" event that would also try to read all the caption's?

Another question:
Is there any "exclude list" to add components?
I saw that it's possible to add Properties to an exclude list. We have a lot of components we don't want to exclude in every form by hand.
I just did this on an project with > 300 forms... was a lot of work.

TIA

Ralf
Back to top
View user's profile Send private message
isiticov
Site Admin


Joined: 21 Nov 2002
Posts: 2103

PostPosted: Wed Jul 28, 2010 5:34 am    Post subject: Reply with quote

Hello,

String constants are translated in UpdateStrings method. So you can call this upon start-up to initialize them with the values from DFM. Also there is an option in TsiLang Expert "Empty string constants", if you deactivate it the Expert won't remove the original value of the constant from the code and it will be always initialized.

There is DoNotTranslate property which allows to exclude components, also there you can add a component's type to exclude all components of such type.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    SiComponents Forums Forum Index -> TsiLang Components Suite All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by p h p B B  © 2001, 2005 p h p B B  Group