Question: How Do You Automate a Process That Involve a GUI (e.g., to save an .xps or .oxps file) Operation with Powershell? You do not want any part to be interactive.
Solution: This applies to PowerShell version 4 and above. This will save the content of c:\temp\contint.txt to goodName.xps in the default folder (often the user’s Documents folder) without needing to attend to the process.
# These three lines (starting with “Add…”,
…
Continue reading “How Do You Automate a Process That Involve a GUI Operation with Powershell?”