[Solved] Input string was not in a correct format

When you want to convert a string to a secure string with ConvertTo-SecureString, you may get the following error message Reason This happens when you try to convert a regular string to a secure string. “Convert To Secure String” string only means “to protect in memory”. However, the standard input for the ConvertTo-SecureString cmdlet is […]

Credential prompt: command line or dialog box?

Technically there is no security difference between the two methods. It’s only a matter of preferences and the behavior depends of a single registry value. Be prompted at the command line Set the ConsolePrompting value to True Be prompted from a dialog box Set the ConsolePrompting value to False or anything else than True. Or […]

Parse log files with PowerShell

If you have to find information in unstructured log files, PowerShell offers a variety of cmdlets that can help you parse text files to extract the information you need. In my last article, I showed you how to search the Windows Event Log with Get-Event. That’s where you usually spot most of the pertinent messages. […]