McKool
Posts: 113
Joined: Wed Jan 19, 2011 12:35 pm
Location: Darmstadt, Germany
Contact:  Website

Change a default project string

Tue Nov 23, 2021 2:10 pm

Hello all,

Advance Installer v 17.1.2
Windows 10 x64

I'm trying to change the message being shown, when a launch condition is not satisfied. My installation uses two languages, english (default) and German. I'm able to change the german translation by using the UI, Project/Translation/Project Strings tab.

My problem is that I also want to adjust the english text, but in the mentioned tab, the english text is disabled and cannot be modified.
ProjectString.PNG
Default project string
ProjectString.PNG (36.92KiB)Viewed 5076 times
I tried already to modify the table "LaunchCondition" but in this case, I always get the text of that table (english), indifferently of which language is being used at installation time.
LaunchConditionTable.PNG
LaunchCondition Table modification
LaunchConditionTable.PNG (16.22KiB)Viewed 5076 times
Another thing that I have tried was to include the Localization Ids for the launch conditions in my own dictionary, since the help states that strings are searched by their localization identifiers in the dictionaries in a descending order:
CustomDictionary.PNG
Custom dictionary on top
CustomDictionary.PNG (10.21KiB)Viewed 5076 times
Custom dictionary extra code:

Code: Select all

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<DICTIONARY type="multilanguage">
  <!-- AI defaults -->
  <ENTRY id="AI.LaunchCondition.NoSpecificNT">
    <STRING lang="de" value="Diese Version von [ProductName] benötigt Windows® 10 oder höher."/>
    <STRING lang="en" value="This version of [ProductNameShort] requires Windows® 10 or higher."/>
  </ENTRY>
  <ENTRY id="AI.LaunchCondition.NoSpecificNT64">
    <STRING lang="de" value="Diese Version von [ProductName] benötigt Windows® 10 oder höher."/>
    <STRING lang="en" value="This version of [ProductNameShort] requires Windows® 10 or higher."/>
  </ENTRY>
  <!-- ActionText table -->
but this also not worked. Can someone please tell me how can I change these texts on the default language so that on an english system the text "This version of [ProductName] requires Windows® 10 or higher" is shwon and on a german system the text "Diese Version von [ProductName] benötigt Windows® 10 oder höher." is shown?

Thanks in advance.

Liviu
Posts: 1035
Joined: Tue Jul 13, 2021 11:29 am
Contact:  Website

Re: Change a default project string

Wed Nov 24, 2021 9:43 am

Hello,

Changing the text of the launch condition directly in the "Table Editor" works only when you have a single-language project.

Since in the "Project Strings" tab you cannot change the English description, the only solution is to edit the string in the .aip file with a text editor, for example notepad:
EnglishString.png
EnglishString.png (193.07KiB)Viewed 5055 times

After editing this, you can see that the description is changed in the project:
afterEditing.png
afterEditing.png (270.94KiB)Viewed 5055 times

Hope this helps! If you have any other questions, please don’t hesitate to contact us.

Best regards,
Liviu
________________________________________
Liviu Sandu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

McKool
Posts: 113
Joined: Wed Jan 19, 2011 12:35 pm
Location: Darmstadt, Germany
Contact:  Website

Re: Change a default project string

Wed Nov 24, 2021 9:58 am

Thanks a lot! it works.

I thought that all text were coming from a dictionary. Didn't know that these were placed in the project file.

Best regards,

Liviu
Posts: 1035
Joined: Tue Jul 13, 2021 11:29 am
Contact:  Website

Re: Change a default project string

Wed Nov 24, 2021 11:17 am

You're welcome!

I'm glad that now everything works as expected.

Best regards,
Liviu
________________________________________
Liviu Sandu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”