Not Passing Transfrom parameter in variable while calling msiexec -ArgumentList

HI,

I am writing a script to install silently a program.

however when I am calling the

Start-Process -FilePath msiexec.exe -ArgumentList $msiArgs -Wait -NoNewWindow

From the script I have this windows pops up saying that the arguments are not properly called.

capture

here is the portion of the code that calls the arguments variable

$msiArgs = @(

"/i"

"/qn"

"$cheminMsi"

"TRANSFORMS=$transforms"

)

And if I take out the transforms part, the code works fine but I need it for a custom installation

Is there an other way of calling it ? thanks.

 

Hi,

Never mind,

I figured it out by just putting the “/qn” at the end in my arguments variable and the installation went through.

$msiArgs = @(

“/i”

“$cheminMsi”

“TRANSFORMS=$transforms”

“/qn”

)

As asked down there, the $transforms variable had the path to the the mst file way up in my code and the $cheminMsi the msi files

Thanks

You should also show us the portion of code that assigns the $transforms, because that seems to be a trouble area - but really, you should just show the entire thing.