Eric's Technical Outlet

Learning the hard way so you don't have to

Monthly Archives: November 2018

Change Default Cmdlet Parameters in Script Without Changing the Global Defaults

PowerShell provides the $PSDefaultParameterValues global variable so that you can pre-configure arguments for specific parameters on cmdlets that you use regularly. But, what if you want to do the same thing in a script? What if you want to do it without breaking anything in the existing global variable? With only a bit of work, you can.

Read more of this post