Problems with TsiLang Expert doesn't include all the Forms.

All announcements, questions and issues related to the TsiLang Components Suite.
Post Reply
James Campion
Posts: 23
Joined: Thu Jan 27, 2005 3:13 pm

Problems with TsiLang Expert doesn't include all the Forms.

Post by James Campion »

How does one manually add the main form to the silLang Expert? MainForm translations are listed in the SIB file prior to loading.
Jim.C
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

As I posted earlier: Could you please check that the main form entry in SIB file is "correct"? It must be named like TYourMainFormName. May be you have changed the name of main form but SIL file used older name?
Best regards,
Igor Siticov.
James Campion
Posts: 23
Joined: Thu Jan 27, 2005 3:13 pm

Post by James Campion »

Unit name is main, Form name = TFormMain. Has not been changed.
TFormMain is listed in both the Sil and SIB files

If I create a separate Sib file from the Main and try to merge it with the master, or simply load project with the main sib file it still doesn't appear.

When I run the Expert it opens all forms in the project except for the Main form.

The expert simply won't registrate the Main form when initiated or when a Sil file or Sib is loaded afterwards.
Jim.C
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

Then it is definitely just wasn't loaded at all. It looks like some problems in project's source. Could you please try the following:
1. Select main form in Expert.
2. Right-click on it and select View Form
Will it display main form?
Please check you project file source (DPR) to list correctly declaration for main form entry.
Please let me know about the results.
Best regards,
Igor Siticov.
James Campion
Posts: 23
Joined: Thu Jan 27, 2005 3:13 pm

Post by James Campion »

I cannot select the main form, it is not listed in the Expert.
Jim.C
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

Then there is definitely problems in your project source. Please check you DPR file, it must include line like the following:

Code: Select all

  main in 'main.pas' {TFormMain},
Best regards,
Igor Siticov.
James Campion
Posts: 23
Joined: Thu Jan 27, 2005 3:13 pm

Post by James Campion »

Sorry I wasn't aware the brackets part of the declaration { } was required by the Expert.
Thank you
Jim.C
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

Actually, this is not required by Expert, but this is required by Delphi IDE.
Best regards,
Igor Siticov.
James Campion
Posts: 23
Joined: Thu Jan 27, 2005 3:13 pm

Post by James Campion »

Hi, I have a problem with the initial logon dialog of our program since changing to SIB files.

We have 2 SIB files that are loaded at runtime,
1. Eng,German,French & Chinese
2. Eng & Russian

If I have loaded nr1. SIb file into the siLang expert and run a build.
The program works fine.

If the other Sib file (eng & russian) is used together with the program and Russian is the startup language, then the captions in the logon dialog is in German (the nr. 2 language as is Russian).
I assumed the translation was in the Exe file so tried to run ”Clear translations” prior to running build.
When I opened up the translations of the logon form in the silang expert the french text is moved to the first language column where the English was.

This results in French appearing everytime in the logon dialog.

The rest of the forms are fine throughout the program with both Sib files.

I use a siLang component on all forms and used the FSIBManager as you suggested to extract language data from the Sib on start up.

FSIBManager.LoadAllFromFile(siLangDispatcher3.FileName);
siLangDispatcher3.LangNames:=FSIBManager.siComponents[0].LangNames;
siLangDispatcher3.Language:=FSIBManager.siComponents[0].Language;
siLangDispatcher3.Language:=CurrentLang_STR;

Any idea why this particular dialogs caption aren't updated?
Jim.C
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

Hi,
The only reason I can suppose is that this logon form is created before! dispatcher or it is loading SIB file before "main" application SIB file. Is this the case?
Best regards,
Igor Siticov.
James Campion
Posts: 23
Joined: Thu Jan 27, 2005 3:13 pm

Post by James Campion »

Yes
The Dispatcher is on the Logon form and in the FormCreate procedure the Sib file is loaded ( using the FSIBManager). The main form is subsequently created when after logon.

This was not a problem with the Sil file but now I can see they are somewhat different.
Jim.C
James Campion
Posts: 23
Joined: Thu Jan 27, 2005 3:13 pm

Post by James Campion »

Any comments to my last reply???
Does the SIB file need to be loaded prior to creation of all forms including the logon?????
To clear the Exe of any translation do I run the "”Clear translations” prior to running build"?
[/quote]
Jim.C
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

No, if you display logon form after the loading of SIB then it is OK.
Yes, using "Clear Translation" prior to build will remove translations from components/EXE.
I just can't see a reason why your logon form displays different tranlsations than presented in SIB. May be there is another place where you also use loading?
Best regards,
Igor Siticov.
Post Reply