MSI Logfile Naming

Hi there,

i’m a newbie to PSADT. In the last weeks, i created a packaging template out of the deploy-application.ps1

for the installation, i adopt the zero msi installation lines

[Hashtable]$ExecuteMSISplat = @{Action = 'Install'; Path = $MSIFile; Parameters = '/QN'; }; If ($MSTFile) {$ExecuteMSISplat.Add('Transform', $MSTFile)} Execute-MSI @ExecuteMSISplat

for uninstall i choose
$newPDC = Get-MsiTableProperty -Path "$scriptDirectory\Files\$MSIFile" -Table 'Property' | Select-Object -ExpandProperty ProductCode Execute-MSI -Action Uninstall -Path $newPDC

Both methods uses the Execute-MSI function and at the result, i get different named msi logs. Why is the naming of it, so different? How did i get the install log looks like the uninstall log in the attachment?

i known of the -LogName Param, but if i use this, i get an error “illegal character”. The only ones are "_"," ' " and " " , is there a problem?

Best Regards

You should post the line with the -LogName parameter that gave you the “illegal character” error.
someone might be able to help.

Hi there,

i think i found the problem. My Logname param was an copy of some parameter (“$appName”+“appVendor”…). The Plus sign is the problem, it was my own stupid.

But the other question is, why is the standard log naming so different?

Best Regards

I don’t know.

Personally, I comment out the zero config stuff.

FYI: you can also do this to avoid using the plus sign:
"$appName$appVendor"