PSSoftware icon indicating copy to clipboard operation
PSSoftware copied to clipboard

Silence the "The operation completed successfully" output when running Import-RegistryFile

Open adbertram opened this issue 10 years ago • 1 comments

adbertram avatar Dec 04 '14 21:12 adbertram

It would appear the simplest way to suppress this message would be to create a temporary file with New-TemporaryFile on PS5 and use the -RedirectStandardError flag on the Start-Process call.

Probably could create a similar function to create our own temporary file to backport this to PS3/4, or could test for New-TempFile and suppress for those that support the function.

"The operation completed successfully" is output to standard error (because clearly it's an error?)

corbob avatar May 06 '18 14:05 corbob