Changes

Jump to: navigation, search

Creating GUIs in Windows PowerShell 1.0 with WinForms

41 bytes added, 19:56, 11 December 2008
Windows PowerShell WinForms Events
</pre>
Using scriptblocks would quickly become unwieldy if all the code to be executed has had to be included along with the add_<eventname> method. An alternative to this approach is to call a function instead. The following adaptation of our example defines a function called ''do_exit'' and subsequently references it in the event handler scriptblock:
<pre>
$form.ShowDialog()
</pre>
 
== Setting WinForms Properties ==

Navigation menu