Need help please, Form with SQL Server connection.


  • Your question wasn't descriptive, but it does touch on something that others may be interested in.

    There are a number of ways to create GUIs in PowerShell. My preferred method is WPF. MVPs Boe Prox and Stephen Owen write a number of good articles about WPF.

    You can do really cool things in WPF. For instance, I created this interface

    The code used to generate this window can be found here. Note that the code-behind is not fully functional, it's just a sample.

    A smaller example is this one, which is less than 50 lines of code:

    I'd paste the code here, but it's not parsing properly. You can find this snippet on Gist.

    If you'd like to use classic Windows Forms, I hacked this together awhile back. 

    Again, you can find the code on Gist. This one is a bit longer, coming in at over 130 lines. It's also not as refined.