Ok, long time visitor, first time post.
Instead of PowerShell telling me the result of my Regular Expression is "True" or "False", instead I would like the string. I know there are other ways to do this and I already have a working version, but I would like to use Regular Expressions to "extract" the string.
For example:
$ipconfig = ipconfig | select-string "IPv4" | select-object -first 1
$ipconfig -match "\b\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}\b"
Just returns "True", instead I would like the IP address.
Is there a way of accomplishing this using regex?
Thanks!