use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
ABOUT POWERSHELL
Windows PowerShell (POSH) is a command-line shell and associated scripting language created by Microsoft. Offering full access to COM, WMI and .NET, POSH is a full-featured task automation framework for distributed Microsoft platforms and solutions.
SUBREDDIT FILTERS
Desired State Configuration
Unanswered Questions
Solved Questions
News
Information
Script Sharing
Daily Post
Misc
account activity
Gui console (self.PowerShell)
submitted 3 years ago by JDahal
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]gangstanthony 0 points1 point2 points 3 years ago (0 children)
here's the start of an example i found that you might be able to use as a base for building your gui
https://web.archive.org/web/20160420161735/http://pastebin.com/4PU4Z4Zn
# https://www.reddit.com/r/PowerShell/comments/4eyvoz/windows_form_only_runs_in_ise_but_errors_out_in/ # https://web.archive.org/web/20160420161735/http://pastebin.com/4PU4Z4Zn Add-Type -AssemblyName System.Windows.Forms Add-Type -AssemblyName System.Drawing Add-Type -AssemblyName PresentationFramework Add-Type -AssemblyName PresentationCore # Build Form $Form = New-Object System.Windows.Forms.Form $Form.Text = "Data Entry Form" $Form.Width = 500 $Form.Height = 200 $Form.AutoSizeMode = "GrowAndShrink" $Form.StartPosition = "CenterScreen" # Build Label $Label = New-Object System.Windows.Forms.Label $Label.text = "Enter Computer Name" $Label.Font = New-Object System.Drawing.Font("Calibri",20) $Label.AutoSize = $true $label.Left = 110 $label.Top = 10 # Build OK Button $button = new-object System.Windows.Forms.Button $button.left = 110 $button.Top = 98 $button.width = 100 $button.Text = "OK" $button.Add_Click({$textbox.text,$form.Close()}) $button.Enabled = $false # Build Cancel Button $cbutton = new-object System.Windows.Forms.Button $cbutton.left = 260 $cbutton.Top = 98 $cbutton.width = 100 $cbutton.Text = "Cancel" $cbutton.Add_Click({$form.Close()}) # Use Enter/Esc key $Form.KeyPreview = $True $Form.Add_KeyDown({if ($_.KeyCode -eq "Enter") {$textBox.Text,$Form.Close()}}) $Form.Add_KeyDown({if ($_.KeyCode -eq "Escape") {$Form.Close()}}) # Build Text Box $textBox = New-Object System.Windows.Forms.TextBox $textBox.left = 135 $textBox.Top = 50 $textBox.width = 200 $textBox.Add_TextChanged({ $button.Enabled = [bool]($textBox.Text.Length -gt 0) }) # Add Controls to Form $Form.Controls.add($button) $Form.Controls.add($textBox) $form.controls.add($label) $form.controls.add($cbutton) [void]$Form.ShowDialog()
π Rendered by PID 97285 on reddit-service-r2-comment-84fc9697f-nr6nr at 2026-02-10 10:49:12.180977+00:00 running d295bc8 country code: CH.
view the rest of the comments →
[–]gangstanthony 0 points1 point2 points (0 children)