Created
August 19, 2014 18:17
-
-
Save fearthecowboy/249486585a393370da64 to your computer and use it in GitHub Desktop.
Dynamic PowerShell from C# using my DynamicPowerShell class
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dynamic ps = new DynamicPowershell(); | |
DynamicPowershellResult result = ps.Dir(@"c:\") ; | |
DynamicPowershellResult result2 = ps.TestPath(result); | |
foreach (var r in result2) { | |
Console.WriteLine(r); // prints true for each item! | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment