I've created installation using WIX V3 with localization to French.
The installation works fine, but then we found out a weird thing:
After installing the produce we try to uninstall it.
During the uninstall we press cancel, and then the installation performing rollback (which is fine). The problem is that during the rollback the statuses appears in English...
For Example:
I've search for the strings in English & French wxl but couldn't fine them.
The installation was tested on French OS.
Does anyone have an idea, where those strings could come from?
Are you referencing the progress strings in your setup?
WiX doesn't include these by default, so you need to ensure that you manually reference them as follows:
<UIRef Id="WixUI_ErrorProgressText" />
Then as long as you're including the French language in your setup (fr-FR), the localized strings will be included.
The ActionText table is not created by default.
You have to create it yourself by adding a UI element to one of your wxs files. This UI element has to contain ProgressText elements. Set the Id attribute of each ProgressText element to the name of a standard action. The inner text of such an element will overwrite the string that is shown for that particular action.
The ProgressText element also has a Template attribute. Take a look at the documentation for each standard action to define the appropriate template here: Standard Actions Reference. I don't know which specific action is displaying the string you are looking for.
It's best to not hardcode the values for each ProgressText element but instead use a localization file. Create two localization strings for each ProgressText element. One for the Template and one for the actual value.
Example
wxs file
<UI>
<ProgressText Action="InstallFiles" Template="!(loc.InstallFilesTemplate)">!(loc.InstallFiles)</ProgressText>
<ProgressText Action="CreateShortcuts" Template="!(loc.CreateShortcutsTemplate)">!(loc.CreateShortcuts)</ProgressText>
<ProgressText Action="WriteRegistryValues" Template="!(loc.WriteRegistryValuesTemplate)">!(loc.WriteRegistryValues)</ProgressText>
<ProgressText Action="RegisterUser" Template="!(loc.RegisterUserTemplate)">!(loc.WriteRegistryValues)</ProgressText>
<ProgressText Action="RegisterProduct" Template="!(loc.RegisterProductTemplate)">!(loc.RegisterProduct)</ProgressText>
<ProgressText Action="PublishFeatures" Template="!(loc.PublishFeaturesTemplate)">!(loc.PublishFeatures)</ProgressText>
<ProgressText Action="PublishProduct" Template="!(loc.PublishProductTemplate)">!(loc.PublishFeatures)</ProgressText>
<ProgressText Action="InstallFinalize" Template="!(loc.InstallFinalizeTemplate)">!(loc.InstallFinalize)</ProgressText>
</UI>
localization file
<String Id="InstallFiles">Installazione del archivos</String>
<String Id="InstallFilesTemplate">Archivo: [1], Tamaño de archivo: [6], Directorio: [9]</String>
<String Id="CreateShortcuts">Creacion de los atajos</String>
<String Id="CreateShortcutsTemplate">Atajo [1] creado</String>
<String Id="WriteRegistryValues">Escribir en registro</String>
<String Id="WriteRegistryValuesTemplate">Camino: [1], Nombre: [2], valor: [3]</String>
<String Id="RegisterUser">Registrar a los usuarios</String>
<String Id="RegisterUserTemplate">Usario: [1]</String>
<String Id="RegisterProduct">Registrar producto</String>
<String Id="RegisterProductTemplate">Producto: [1]</String>
<String Id="PublishFeatures">Publicar las características</String>
<String Id="PublishFeaturesTemplate">Caraterística: [1]</String>
<String Id="PublishProduct">Publicar el producto</String>
<String Id="PublishProductTemplate">Producto: [1]</String>
<String Id="InstallFinalize">Finalizar la instalación</String>
<String Id="InstallFinalizeTemplate">Finalizar [ProductName]</String>
note: i don't know spanish, i just let google translate it.
Here is list of the standard actions occuring in the correct order you might want to take a look at:
InstallInitialize Action
ProcessComponents Action
InstallFiles Action
CreateShortcuts Action
WriteRegistryValues Action
RegisterUser Action
RegisterProduct Action
PublishFeatures Action
PublishProduct Action
InstallFinalize Action
My knowledge is based on a book with the following ISBN: 978-1782160427
Related
We are trying to show the localized value for a "dynamic" enum.
In our backoffice-config.xml We have something like this
<context type="CustomeType" component="base" merge-by="type">
<y:base xmlns:y="http://www.hybris.com/cockpit/config/hybris">
<y:labels>
<y:label>customProperty.hybrisEnumValueProperty.name</y:label>
</y:labels>
</y:base>
</context>
With this we receive the default TypeName(Pk) in backoffice instead of the localized name. For the code it works just fine. Also for hmc it works as well.
You need to add localization text for these enums like below.
mycoreextension-items.xml
<enumtype code="myenum" generate="true" dynamic="true">
<value code="ENUM1" />
<value code="ENUM2" />
</enumtype>
mycoreextension-locales_en.properties
type.myenum.name=My Enum Name
type.myenum.description=My enum description
type.myenum.enum1.name=My enum value 1
type.myenum.enum2.name=My enum value 1
I'm upgrading a Wix installer to a Wix bundle. The installer is for a application that supports only one language, so I need the bundle's UI to be in that same language.
To change the wix installer's UI Language, I used the Language property of the Product tag (1046 is locale code for the language I want):
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Product Name="My aplication" ... Language="1046">
...
</Product>
</Wix>
Can I change the Language of the bundle's default UI? How?
My bundle:
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Bundle
Name="..."
Version="..."
Manufacturer="..."
UpgradeCode="...">
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.HyperlinkLicense">
<bal:WixStandardBootstrapperApplication
LicenseUrl=""
SuppressOptionsUI="yes"
xmlns:bal="http://schemas.microsoft.com/wix/BalExtension" />
</BootstrapperApplicationRef>
<Chain>
<PackageGroupRef Id="NetFx40Web"/>
<MsiPackage Id="..." SourceFile="..."/>
</Chain>
</Bundle>
</Wix>
Bundles don't have a language as they're usually used to install both neutral and many localized resources. WixStdBA automatically tries to show its UI with localized strings matching the user's chosen locale. But if you only ship English strings, for example, only English strings will be shown. You can choose a localization file (.wxl) using the WixStandardBootstrapperApplication/#LocalizationFile attribute.
(Today, only English strings are available for WixStdBA so you'd have to translate the .wxl strings if you want another language.)
How is it possible to add translations of strings to the felogin plugin? I slowly start to get the convention for templates (directing to the modified templates in the plugin's typoscript configuration) but that does not work with the locallang. The original messages are in English in the xlf format, located in the plugin's folder. I know this can be done in TypoScript but I do not like to have the strings defined so incosistently. (I guess modifying that original file is not the proper way.)
Overriding labels by TypoScript is the way to go. Manually editing the l10n files is a really bad idea - these files are overwritten on updating the translations. If the extension gets an update and new labels are added, you will want to perform the updates.
The change from XML files for translation to the XLIFF format didn't change anything in the best practise you should use for adjusting labels according to your needs. It's just another format with a standardized translation server (Pootle) that (in theory) allows some special features like e.g. plural forms.
Conclusion: Use TypoScript.
For the default language (no config.language set) use:
plugin.tx_felogin_pi1._LOCAL_LANG.default {
key = value
}
For a specific language, e.g. German, use
plugin.tx_felogin_pi1._LOCAL_LANG.de {
key = value
}
The best way is to use the following code:
ext_tables.php, e.g. of your theme extension with
$GLOBALS['TYPO3_CONF_VARS']['SYS']['locallangXMLOverride']['EXT:felogin/Resources/Private/Language/locallang.xlf'][] = 'EXT:theme/Resources/Private/Language/locallang_felogin.xlf';
and in this file you can use something like
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<xliff version="1.0">
<file source-language="en" datatype="plaintext" original="messages" date="2015-06-30T21:14:27Z">
<header>
<description>Language labels for felogin</description>
</header>
<body>
<trans-unit id="permalogin">
<source>An diesem Rechner angemeldet bleiben</source>
</trans-unit>
<trans-unit id="ll_forgot_header">
<source>Passwort vergessen?</source>
</trans-unit>
<trans-unit id="ll_welcome_header">
<source>Sie betreten den Händlerbereich</source>
</trans-unit>
<trans-unit id="ll_welcome_message">
<source>Bitte loggen Sie sich ein.</source>
</trans-unit>
</body>
</file>
</xliff>
You can use the BE language module to download preconfigured locallangs for every language you need.
The files are stored in e.g. typo3conf/l10n/de/fe_login.
You can edit these files manually in l10n to get your own strings inside or use an extension like snowbabal to do the editing inside a BE module.
Wix I18n Dev.The version of wixtoolset is V3.7.
And the Installer UI is created by UIExtension.
In the installation process, there are some UI strings cannot be localized. Such as "Copying new files" and so on. I searched these strings and there are laid in the wix source code(wix37-sources\src\ext\UIExtension\wixlib\WixUI_en-us.wxl), and wix has localized these strings.
It's confusing to me that wix has localized these strings, but it still displayed as English in the installation process. Even I replaced there strings in .wxl file ,it still displayed as English strings.
I tried the example of BdN3504.
the wxs file is the same as BdN3504.
the wxl file is
and you can see the status is still keep English.
My build environment is VS2010 & wix3.7. I don't know what's wrong with it....
I already answered this question here.
Either read that or check out the paragraph called Progress Bar Messages in Nick Ramirez' book WiX 3.6: A Developer's Guide to Windows.
The good people of packtpublishing are offering the chapter of his book containing that paragraph for free here:
Chapter 12: Localizing Your Installer. See page 329.
Another page of interest is this MSDN article: Standard Actions Reference which is also noted in the book.
Edit: Because of the comments I will post a working minimal example and a screenshot, so you see that it works:
<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Product Id="*" Name="LocalizingErrors" Language="1034" Version="1.0.0.0" Manufacturer="SomeOne" UpgradeCode="7ddbcad4-98d9-4c2d-9ae6-6fdc47314947">
<Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" />
<MediaTemplate EmbedCab="no" />
<Feature Id="ProductFeature" Title="LocalizingErrors" Level="1">
<ComponentGroupRef Id="ProductComponents" />
</Feature>
<!-- Custom Progress messages
Custom progress messages are defined by a table in the MSI called ActionText. However, by default
this table isn't included. Without it, the messages are the stock English versions.
To add the ActionText table with strings for progress messages, add a ProgressText element inside
a UI element for each standard action found in the Execute sequence. For example, to add a
localized message for the InstallFiles action, add the following markup to one of your wxs files:
-->
<UI>
<ProgressText Action="InstallFiles" Template="!(loc.InstallFilesTemplate)">!(loc.InstallFiles)</ProgressText>
<ProgressText Action="CreateShortcuts" Template="!(loc.CreateShortcutsTemplate)">!(loc.CreateShortcuts)</ProgressText>
<ProgressText Action="WriteRegistryValues" Template="!(loc.WriteRegistryValuesTemplate)">!(loc.WriteRegistryValues)</ProgressText>
<ProgressText Action="RegisterUser" Template="!(loc.RegisterUserTemplate)">!(loc.WriteRegistryValues)</ProgressText>
<ProgressText Action="RegisterProduct" Template="!(loc.RegisterProductTemplate)">!(loc.RegisterProduct)</ProgressText>
<ProgressText Action="PublishFeatures" Template="!(loc.PublishFeaturesTemplate)">!(loc.PublishFeatures)</ProgressText>
<ProgressText Action="PublishProduct" Template="!(loc.PublishProductTemplate)">!(loc.PublishFeatures)</ProgressText>
<ProgressText Action="InstallFinalize" Template="!(loc.InstallFinalizeTemplate)">!(loc.InstallFinalize)</ProgressText>
</UI>
<UIRef Id="WixUI_Minimal"/>
</Product>
<Fragment>
<Directory Id="TARGETDIR" Name="SourceDir">
<Directory Id="ProgramFilesFolder">
<Directory Id="INSTALLFOLDER" Name="LocalizingErrors" />
</Directory>
</Directory>
</Fragment>
<Fragment>
<ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER">
<Component Id="ProductComponent" Guid="92A175A0-D15D-48EC-B2E1-FD5848FB6430">
<File Id="somefile" Source="..\File.exe" KeyPath="yes" />
</Component>
</ComponentGroup>
</Fragment>
</Wix>
Accompanying this example, you have to have a localisation file for your Culture. You have to set the Culture in the project properties under Build->Cultures to build. In my case I named it es-es.wxl and the file contents follow:
<?xml version="1.0" encoding="utf-8"?>
<WixLocalization Culture="es-es" xmlns="http://schemas.microsoft.com/wix/2006/localization" Codepage="1252" Language="1034">
<String Id="Error_1311">Archivo no encontrado: [2]. Compruebe que el archivo existe y que puedes acceder a él.</String>
<String Id="InstallFiles">Installazione del archivos</String>
<String Id="InstallFilesTemplate">Archivo: [1], Tamaño de archivo: [6], Directorio: [9]</String>
<String Id="CreateShortcuts">Creacion de los atajos</String>
<String Id="CreateShortcutsTemplate">Atajo [1] creado</String>
<String Id="WriteRegistryValues">Escribir en registro</String>
<String Id="WriteRegistryValuesTemplate">Camino: [1], Nombre: [2], valor: [3]</String>
<String Id="RegisterUser">Registrar a los usuarios</String>
<String Id="RegisterUserTemplate">Usario: [1]</String>
<String Id="RegisterProduct">Registrar producto</String>
<String Id="RegisterProductTemplate">Producto: [1]</String>
<String Id="PublishFeatures">Publicar las características</String>
<String Id="PublishFeaturesTemplate">Caraterística: [1]</String>
<String Id="PublishProduct">Publicar el producto</String>
<String Id="PublishProductTemplate">Producto: [1]</String>
<String Id="InstallFinalize">Finalizar la instalación</String>
<String Id="InstallFinalizeTemplate">Finalizar [ProductName]</String>
</WixLocalization>
Lastly a Screenshot to show you that it works:
Another edit: To localize error strings, you simply have to define Error elements with the corresponding error numbers:
<UI>
<Error Id="1322">Una parte de la ruta de la carpeta no es válido. Se está vacío o supera la longitud permitida por el sistema.</Error>
<Error Id="1311">!(loc.Error_1311)</Error>
</UI>
The first error string is hard-coded, so that's not such a good solution. It's better to use localization files, as it is done in the second Error element.
I'm trying to change values in my application.properties file and I'm running into issues with an extra "\" character when trying to substitute url addresses. It doesn't happen when I'm replacing regular text.
Here's the section of the properties file I'm attempting to modify:
# Web Info
web.url=http://www.testaddress.com
web.user=TestAccount
Here's the section of my script that's not working correctly:
<propertyfile file="application.properties">
<entry key="web.url" operation="=" value="${webaddress}" />
<entry key="web.user" operation="=" value="${username}" />
</propertyfile>
What happens is that the web.user is replaced just fine but the address comes out looking like so:
# Web Info
web.url=http\://www.realaddress.com
web.user=RealAccount
I can't account for the backslash, if I echo the ${webaddress} variable it doesn't have it. Any idea as to what may be going on?
Thanks.
Check out the "store" method of the Properties object. The javadoc specifically states:
The key and element characters #, !,
=, and : are written with a preceding backslash to ensure that they are
properly loaded.