Hello,
Could anyone tell me how to pass multiple .mst files to the Execute-MSI command?
I found the info that they are expected to be in the same directory as the .msi file (which they are) and that they should be separated with a semicolon.
Here’s how I understand this should work:
Execute-MSI -Action Install -Path 'Rolltalk Designer.msi' -Parameters '/QN' -Transform '1030.mst;1033.mst;1044.mst;1053.mst'
It works when I pass only one argument (e.g. -Transform '1030.mst'
)
However, when I pass more than one .mst file, I get the following error:
[05-06-2024 05:40:14.170] [Installation] [Execute-Process] :: Execution failed with exit code [1624]: Error applying transforms. Verify that the specified transform paths are valid.
Hi!
Try to include each transform in ’ ’ like -Transform ‘1030.mst’;‘1033.mst’;‘1044.mst’
Good luck!
Looking at the code, it splits up the string with ; then appends the MSI parent path to each MST file, then rejoins with ; and wraps with double quotes.
If this is not working, or your MST files are in a different location, another way would be to use -AddParameters to add your desired TRANSFORMS property without PSADT trying to modify it.
If there is indeed a bug here, I would propose that we stop trying to expand the full paths as MSIEXEC doesn’t need this for the TRANSFORMS property, it assumes the same folder as the MSI by default. You only need to supply a full path for the PATCH property.
Also, you should never apply all the language transforms at once like that - they overwrite the same settings like ProductLanguage, just pick one!