Special character in product name breaks mtx filename

Got a problem you cannot solve? Try here.
Martin H.
Posts: 2
Joined: Tue Oct 19, 2021 10:23 am

Special character in product name breaks mtx filename

Postby Martin H. » Tue Oct 19, 2021 10:57 am

I have an issue with special characters in product name.
As I understand the mtx language file needs to have the same file name as the product name. For example, if I have set the product name to "MyProduct", the file is named "MyProduct.mtx".
If I use, for example, a colon in the product name, say "My:Product", it is not possible to have a matching mtx-file, because of the colon, which can not be used in filenames.
My current solution for this problem (found in this forum) is as follows. I set product name to "MyProduct" and in the first line of MSI code I set the variable TITLE to "My:Product". It works fine in setup dialogs. But it is displayed not correct in the UAC dialog asking for admin rights and some other small startup dialogs preparing the setup. The text for product name displayed there is still "MyProduct" (without colon).
Running the localization wizard in InstallAware, also breaks with an error if product name contains a colon.

Is there a way to set product name with special characters or to achieve, in addition to my above solution, displaying product name with special characters in UAC and startup dialogs, too?

FrancescoT
Site Admin
Posts: 5218
Joined: Sun Aug 22, 2010 4:28 am

Re: Special character in product name breaks mtx filename

Postby FrancescoT » Thu Oct 21, 2021 9:31 am

You may use special characters with the "Product Name". This can be easily done with assigning a new "Product Name" succesively the project creation.
special chars.png
special chars.png (69.79 KiB) Viewed 1099 times


However this introduces some limitations with the use of the $TITLE$ pre-derfinerd variable, and this because by default, this variable points to the name of the product being installed, as set in the Product Name field of the project options dialog.

Consequently if you really want to have special characters with the "Product Name", you have also to consider that the $TITLE$ variable cannot be used anymore with those script commands where special characters are not allowed (ex. Install Files, Copy Files, Create Folder, Create Shortcut and so on).

Hope this helps you.
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE

Martin H.
Posts: 2
Joined: Tue Oct 19, 2021 10:23 am

Re: Special character in product name breaks mtx filename

Postby Martin H. » Tue Oct 26, 2021 7:44 am

Thank you for your answer. But it does not resolve my problem with the mtx-file when setup should be localized.
InstallAware names the mtx-file identical to the project name. If project name has special characters it can not be localized.

localize.png
localize.png (21.54 KiB) Viewed 952 times


Best regards
Martin

FrancescoT
Site Admin
Posts: 5218
Joined: Sun Aug 22, 2010 4:28 am

Re: Special character in product name breaks mtx filename

Postby FrancescoT » Wed Oct 27, 2021 1:06 pm

I see what you mean.

Unfortunately the Localization process uses the assigned project name when generating the MTX file...and there isn't a workaround for this.
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE


Return to “Technical Support”

Who is online

Users browsing this forum: Bing [Bot] and 18 guests