Hi all,
So I have a couple of scripts where I am using a Get-Credential in them. What I’m looking to do is to change the text that is written to the PowerShell window when it occurs in the code. The prompt itself and everything else about it is working fine, I’m just looking to clean up the output slightly. When my function gets to the $cred = Get-credential the host window outputs:
cmdlet Get-Credential at command pipeline position 1
Supply values for the following parameters:
Credential
Ideally I would like it to instead read something like
Please enter credentials for the SQL Server
I know that normally you can do a read-host for something like this but being that get-credential is a specialized cmdlet I didn’t know how to go about that.
Thanks!
Jarrod