After running, I am prompted with the msiexec help window, no matter the changes I make to the code. This works fine, however, I was attempting to add the logging option:
@krzydoug I really appreciate the quick response. I made the suggested change, but the result is still the same. Would you happen to have any other ideas?
@Olaf, I just get one file. I use wildcards so that I can just dump the latest update in the folder and run the script. Thanks for the tip on shortening the code!
@Olaf that seems to work until I change $UpdateDirectory to $PSScriptRoot in the script. I put these scripts on a disc that is ran on multiple machines, and the drive letter for optical media varies from system to system.
So you have to start debugging your code. Start with outputting the variables youy use to the console and check if the output is what you expect it to be.