Page 1 of 1

Problems with resource strings

Posted: Mon Jul 12, 2004 7:39 pm
by Nico
I´ve a specific unit for store resource strings (uResourceStrings.pas) wich has a form where a TSILang component is placed. I put a dispatcher aswell in another unit (uDispatcher).
All the traductions in my application are working well except by all the resource strings (none is working).
I ran the wizard (in the TSILangExpert) and imported the strings from the PE file. This worked fine, but when I ran the program, the problem is still there (no translation at all with resource strings).
I really don´t know what to do next... :(

PS = I don´t want to use resource strings as Const...


For example:
// in xxx.pas
showmessage(MSG)

// in uResourceStrings

resourcestring
MSG = 'This is a message';

Sorry for my poor english...

Posted: Tue Jul 13, 2004 4:50 am
by isiticov
Please check the following:
1. You TsiLang which has resource strings stored has ResourceHandler property set to True.
2. Only ONE :!: TsiLang per project is responsible for translating resource strings.
3. Your form which holds this TsiLang is :!: auto-created or created manually before retrieving any resource string to display.

Hope this helps.

Posted: Tue Jul 13, 2004 12:52 pm
by Nico
Thnks isiticov... :D But I checked all you said and nothing happens. :cry:

1) Was ok on my project (I assume that the property is "HandleResourceStrings")
2) Was ok on my project.
3) When you say "before retrieving any resource string to display", I don´t know wen thats happens... In other way, I´ve to retrieve manually the resourcestrings??

Again... Thanks a lot!

Posted: Tue Jul 13, 2004 1:30 pm
by Nico
I found the solution!
Like you said... only one form is the responsable of managging resource strings... Well, I´ve the property HandleResourceStrings set to true on ALL mi forms!!!! So I set this prop to true only in the form where I put my resourcestrings and WORKS! :D

Thanks a lot!

Posted: Tue Jul 13, 2004 6:13 pm
by isiticov
Glad to see this! :)