For the last few months I’ve been learning how-to create Powershell scripts to help manage our servers and build
solutions for our users. First, I will show a sample C# code that will display a more complex messagebox in action.
You can build a windows form with a button control and then add the C# code to test that this code works.
Here’s the C# code:
Here’s the converted C# code to Powershell syntax:
Make sure to add this Powershell code to a *.ps1 file to run it. Or, just copy/paste code to the shell to run interactive.
Now, you might asked the question, Can I build and convert a simple Windows form(s) solution to a Powershell syntax?
The answer is YES. Happy Powershell coding!