{"id":2689,"date":"2013-01-10T10:24:35","date_gmt":"2013-01-10T15:24:35","guid":{"rendered":"http:\/\/jdhitsolutions.com\/blog\/?p=2689"},"modified":"2013-01-10T10:24:35","modified_gmt":"2013-01-10T15:24:35","slug":"powershell-screen-shots","status":"publish","type":"post","link":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/","title":{"rendered":"PowerShell Screen Shots"},"content":{"rendered":"<p>Yesterday I posted a tool that creates a <a href=\"http:\/\/bit.ly\/SkCSvN\" title=\"read about Out-ConsoleGraph\" target=\"_blank\">console-based graph<\/a>. That command uses Write-Host which means nothing is sent to the pipeline. The only way you can really save the result is with a screen capture. Of course, you can manually use whatever screen capture program you like. If you have something like <a href=\"http:\/\/www.techsmith.com\/snagit.html\" title=\"Learn more about Snagit.\" target=\"_blank\">Snagit <\/a>you can even capture a scrolling window which is handy if your graph is longer than your console window size.<\/p>\n<p>But perhaps you'd prefer a more automated approach using PowerShell. There are a number of scripts out there which you can use, including a nice one from <a href=\"http:\/\/learn-powershell.net\/\" title=\"visit Boe's blog\" target=\"_blank\">Boe Prox<\/a> which you can find <a href=\"http:\/\/gallery.technet.microsoft.com\/scriptcenter\/eeff544a-f690-4f6b-a586-11eea6fc5eb8\" target=\"_blank\">here<\/a>. For better or worse, alot of these scripts turn to .NET style programming. There's nothing wrong with that unless you are struggling to understand the script and lack the necessary .NET background. So I took a cue from a recipe I came across from <a href=\"http:\/\/www.leeholmes.com\/blog\/\" title=\"visit Lee's blog\" target=\"_blank\">Lee Holmes<\/a> on sending keystrokes to \"press\" the PrintScreen button. My function then takes that output from the clipboard and saves it to a file.<\/p>\n<p><code lang=\"PowerShell\"><br \/>\nFunction New-ScreenShot {<\/p>\n<p>#comment based help is here<\/p>\n<p>[cmdletbinding(SupportsShouldProcess=$True)]<\/p>\n<p>Param(<br \/>\n[Parameter(Position=0,Mandatory=$True,HelpMessage=\"Enter the path and filename\")]<br \/>\n[ValidateNotNullorEmpty()]<br \/>\n[ValidateScript({<br \/>\n#verify the folder exists<br \/>\n$folder = Split-Path -Path $_<\/p>\n<p>#Validation differs depending on whether v2 or v3<br \/>\nif ($PSVersionTable.psversion -eq \"2.0\") {<br \/>\n   Test-Path -Path $folder<br \/>\n}<br \/>\nelse {<br \/>\n    if (! (Test-Path -Path $folder)) {<br \/>\n        #write a custom error message for v3<br \/>\n        Throw \"Can't verify that $folder exists.\"<br \/>\n    }<br \/>\n    else {<br \/>\n        $True<br \/>\n    }<br \/>\n }<br \/>\n})]<br \/>\n[string]$Path,<br \/>\n[switch]$Full,<br \/>\n[switch]$Passthru<br \/>\n)<\/p>\n<p>If ($host.Runspace.ApartmentState -ne \"STA\") {<br \/>\n    Write-Warning \"You must run this in a PowerShell session with an apartment state of STA\"<br \/>\n    Return<br \/>\n}<\/p>\n<p>#load the necessary assemblies<br \/>\nAdd-Type -AssemblyName \"System.Drawing\",\"System.Windows.Forms\"<\/p>\n<p>if ($Full) {<br \/>\n    #capture the full desktop<br \/>\n    [Windows.Forms.Sendkeys]::SendWait(\"{PrtSc}\")<br \/>\n}<br \/>\nelse {<br \/>\n    #capture the current window<br \/>\n    [Windows.Forms.Sendkeys]::SendWait(\"%{PrtSc}\")<br \/>\n}<\/p>\n<p>#pause enough to give time for the capture to take place<br \/>\nstart-sleep -Milliseconds 250<\/p>\n<p>#create bitmap object from the screenshot<br \/>\n$bitmap = [Windows.Forms.Clipboard]::GetImage()  <\/p>\n<p>#split off the file extension and use it as the type<br \/>\n[string]$filename=Split-Path -Path $Path -Leaf<br \/>\n[string]$FileExtension= $Filename.Split(\".\")[1].Trim()<\/p>\n<p>#get the right format value based on the file extension<br \/>\nSwitch ($FileExtension) {<br \/>\n    \"png\"  {$FileType=[System.Drawing.Imaging.ImageFormat]::Png}<br \/>\n    \"bmp\"  {$FileType=[System.Drawing.Imaging.ImageFormat]::Bmp}<br \/>\n    \"gif\"  {$FileType=[System.Drawing.Imaging.ImageFormat]::Gif}<br \/>\n    \"emf\"  {$FileType=[System.Drawing.Imaging.ImageFormat]::Emf}<br \/>\n    \"jpg\"  {$FileType=[System.Drawing.Imaging.ImageFormat]::Jpeg}<br \/>\n    \"tiff\" {$FileType=[System.Drawing.Imaging.ImageFormat]::Tiff}<br \/>\n    \"wmf\"  {$FileType=[System.Drawing.Imaging.ImageFormat]::Wmf}<br \/>\n    \"exif\" {$FileType=[System.Drawing.Imaging.ImageFormat]::Exif}<\/p>\n<p>    Default {<br \/>\n      Write-Warning \"Failed to find a valid graphic file type\"<br \/>\n      $FileType=$False<br \/>\n      }<br \/>\n} #switch<\/p>\n<p>#Save the file if a valid file type was determined<br \/>\nif ($FileType) {<\/p>\n<p> If ($PSCmdlet.ShouldProcess($path)) {<br \/>\n    Try {<br \/>\n        $bitmap.Save($Path.Trim(),$FileType)<br \/>\n        if ($Passthru) {<br \/>\n            #write the file object to the pipeline<br \/>\n            Get-Item -Path $Path.Trim()<br \/>\n        } #if $passthru<br \/>\n    } #try<br \/>\n    Catch {<br \/>\n        Write-Warning \"Failed to save screen capture. $($_.Exception.Message)\"<br \/>\n    } #catch<br \/>\n } #if shouldprocess<br \/>\n} #if $filetype<\/p>\n<p>#clear the clipboard<br \/>\n[Windows.Forms.Clipboard]::Clear()<\/p>\n<p>} #end function<br \/>\n<\/code><\/p>\n<p>The function will work in both v2 and v3. One thing I've done a little differently is to add validation for the Path parameter. PowerShell v3 changed how parameters are bound and validated so in v3 I can throw a custom error message that it a bit more meaningful instead the usual, \"the validation script failed\".<\/p>\n<p>The default behavior is to capture the current Window. But you can use -Full to capture the complete desktop. As long as you specify a valid file type, the screen shot is automatically saved. Because the function creates something new I went ahead and added support for -WhatIf. I also threw in -Passthru as most of the time you don't really need to see the output but sometimes you might.<\/p>\n<p>Now that I have this tool, I can build scripts to create a console graph and snap a screen shot.<\/p>\n<p><code lang=\"PowerShell\"><br \/>\n#requires -version 3.0<\/p>\n<p>Param (<br \/>\n[string]$Path=\"C:\\Scripts\",<br \/>\n[string]$File=\"c:\\work\\screen.png\"<br \/>\n)<\/p>\n<p>#dot source necessary functions<br \/>\n. C:\\scripts\\Out-ConsoleGraph.ps1<br \/>\n. C:\\scripts\\New-ScreenShot.ps1<\/p>\n<p>#save the current window title<br \/>\n$CurrentTitle = $host.ui.RawUI.WindowTitle<\/p>\n<p>#set a new, temporary title<br \/>\n$host.ui.RawUI.WindowTitle = \"File Extension Report by Count for $path\"<\/p>\n<p>#get all files that have an extension<br \/>\n$data = dir $path -Recurse -File | where Extension<br \/>\n$groups = $data | Group-Object -Property Extension<br \/>\n$groups | sort Count -Descending | Select -first 20 |<br \/>\nOut-ConsoleGraph -Property Count -GraphColor Magenta -ClearScreen |<br \/>\nNew-ScreenShot -Path $file<\/p>\n<p>#set the title back<br \/>\n$host.ui.RawUI.WindowTitle = $CurrentTitle<br \/>\n<\/code><\/p>\n<p>Because the screen shot happens before the script finishes I'm also taking advantage of the console title bar to add more information.<\/p>\n<p><a href=\"http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/screen.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/screen-1024x703.png\" alt=\"screenshot\" width=\"625\" height=\"429\" class=\"aligncenter size-large wp-image-2691\" srcset=\"https:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/screen-1024x703.png 1024w, https:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/screen-300x206.png 300w, https:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/screen-624x428.png 624w, https:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/screen.png 1137w\" sizes=\"auto, (max-width: 625px) 100vw, 625px\" \/><\/a><\/p>\n<p>A few caveats: PowerShell must be run in STA mode. The function will check and warn you if the console is in the \"wrong\" mode. And because I'm using common key commands, this might conflict with any installed screen capture programs like Snagit. As the code says, this is a quick and dirty approach but I think it is easy to understand what each part of the function is doing.<\/p>\n<p>You can download <a href=\"http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/New-ScreenShot.txt\" target='_blank'>New-ScreenShot<\/a> and try things our for yourself.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Yesterday I posted a tool that creates a console-based graph. That command uses Write-Host which means nothing is sent to the pipeline. The only way you can really save the result is with a screen capture. Of course, you can manually use whatever screen capture program you like. If you have something like Snagit you&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[4,8],"tags":[534,540],"class_list":["post-2689","post","type-post","status-publish","format-standard","hentry","category-powershell","category-scripting","tag-powershell","tag-scripting"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>PowerShell Screen Shots &#8226; The Lonely Administrator<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"PowerShell Screen Shots &#8226; The Lonely Administrator\" \/>\n<meta property=\"og:description\" content=\"Yesterday I posted a tool that creates a console-based graph. That command uses Write-Host which means nothing is sent to the pipeline. The only way you can really save the result is with a screen capture. Of course, you can manually use whatever screen capture program you like. If you have something like Snagit you...\" \/>\n<meta property=\"og:url\" content=\"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/\" \/>\n<meta property=\"og:site_name\" content=\"The Lonely Administrator\" \/>\n<meta property=\"article:published_time\" content=\"2013-01-10T15:24:35+00:00\" \/>\n<meta property=\"og:image\" content=\"http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/screen-1024x703.png\" \/>\n<meta name=\"author\" content=\"Jeffery Hicks\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@JeffHicks\" \/>\n<meta name=\"twitter:site\" content=\"@JeffHicks\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Jeffery Hicks\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/2689\\\/powershell-screen-shots\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/2689\\\/powershell-screen-shots\\\/\"},\"author\":{\"name\":\"Jeffery Hicks\",\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/#\\\/schema\\\/person\\\/d0258030b41f07fd745f4078bdf5b6c9\"},\"headline\":\"PowerShell Screen Shots\",\"datePublished\":\"2013-01-10T15:24:35+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/2689\\\/powershell-screen-shots\\\/\"},\"wordCount\":434,\"commentCount\":4,\"publisher\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/#\\\/schema\\\/person\\\/d0258030b41f07fd745f4078bdf5b6c9\"},\"image\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/2689\\\/powershell-screen-shots\\\/#primaryimage\"},\"thumbnailUrl\":\"http:\\\/\\\/jdhitsolutions.com\\\/blog\\\/wp-content\\\/uploads\\\/2013\\\/01\\\/screen-1024x703.png\",\"keywords\":[\"PowerShell\",\"Scripting\"],\"articleSection\":[\"PowerShell\",\"Scripting\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/2689\\\/powershell-screen-shots\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/2689\\\/powershell-screen-shots\\\/\",\"url\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/2689\\\/powershell-screen-shots\\\/\",\"name\":\"PowerShell Screen Shots &#8226; The Lonely Administrator\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/2689\\\/powershell-screen-shots\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/2689\\\/powershell-screen-shots\\\/#primaryimage\"},\"thumbnailUrl\":\"http:\\\/\\\/jdhitsolutions.com\\\/blog\\\/wp-content\\\/uploads\\\/2013\\\/01\\\/screen-1024x703.png\",\"datePublished\":\"2013-01-10T15:24:35+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/2689\\\/powershell-screen-shots\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/2689\\\/powershell-screen-shots\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/2689\\\/powershell-screen-shots\\\/#primaryimage\",\"url\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/wp-content\\\/uploads\\\/2013\\\/01\\\/screen.png\",\"contentUrl\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/wp-content\\\/uploads\\\/2013\\\/01\\\/screen.png\",\"width\":1137,\"height\":781},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/2689\\\/powershell-screen-shots\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"PowerShell\",\"item\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/category\\\/powershell\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"PowerShell Screen Shots\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/\",\"name\":\"The Lonely Administrator\",\"description\":\"Practical Advice for the Automating IT Pro\",\"publisher\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/#\\\/schema\\\/person\\\/d0258030b41f07fd745f4078bdf5b6c9\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/#\\\/schema\\\/person\\\/d0258030b41f07fd745f4078bdf5b6c9\",\"name\":\"Jeffery Hicks\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/832ae5d438fdcfc1420d720cd1991307927de8a0b12f2342e81c30f773e21098?s=96&d=wavatar&r=pg\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/832ae5d438fdcfc1420d720cd1991307927de8a0b12f2342e81c30f773e21098?s=96&d=wavatar&r=pg\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/832ae5d438fdcfc1420d720cd1991307927de8a0b12f2342e81c30f773e21098?s=96&d=wavatar&r=pg\",\"caption\":\"Jeffery Hicks\"},\"logo\":{\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/832ae5d438fdcfc1420d720cd1991307927de8a0b12f2342e81c30f773e21098?s=96&d=wavatar&r=pg\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"PowerShell Screen Shots &#8226; The Lonely Administrator","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/","og_locale":"en_US","og_type":"article","og_title":"PowerShell Screen Shots &#8226; The Lonely Administrator","og_description":"Yesterday I posted a tool that creates a console-based graph. That command uses Write-Host which means nothing is sent to the pipeline. The only way you can really save the result is with a screen capture. Of course, you can manually use whatever screen capture program you like. If you have something like Snagit you...","og_url":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/","og_site_name":"The Lonely Administrator","article_published_time":"2013-01-10T15:24:35+00:00","og_image":[{"url":"http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/screen-1024x703.png","type":"","width":"","height":""}],"author":"Jeffery Hicks","twitter_card":"summary_large_image","twitter_creator":"@JeffHicks","twitter_site":"@JeffHicks","twitter_misc":{"Written by":"Jeffery Hicks","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/#article","isPartOf":{"@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/"},"author":{"name":"Jeffery Hicks","@id":"https:\/\/jdhitsolutions.com\/blog\/#\/schema\/person\/d0258030b41f07fd745f4078bdf5b6c9"},"headline":"PowerShell Screen Shots","datePublished":"2013-01-10T15:24:35+00:00","mainEntityOfPage":{"@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/"},"wordCount":434,"commentCount":4,"publisher":{"@id":"https:\/\/jdhitsolutions.com\/blog\/#\/schema\/person\/d0258030b41f07fd745f4078bdf5b6c9"},"image":{"@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/#primaryimage"},"thumbnailUrl":"http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/screen-1024x703.png","keywords":["PowerShell","Scripting"],"articleSection":["PowerShell","Scripting"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/","url":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/","name":"PowerShell Screen Shots &#8226; The Lonely Administrator","isPartOf":{"@id":"https:\/\/jdhitsolutions.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/#primaryimage"},"image":{"@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/#primaryimage"},"thumbnailUrl":"http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/screen-1024x703.png","datePublished":"2013-01-10T15:24:35+00:00","breadcrumb":{"@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/#primaryimage","url":"https:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/screen.png","contentUrl":"https:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/screen.png","width":1137,"height":781},{"@type":"BreadcrumbList","@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2689\/powershell-screen-shots\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"PowerShell","item":"https:\/\/jdhitsolutions.com\/blog\/category\/powershell\/"},{"@type":"ListItem","position":2,"name":"PowerShell Screen Shots"}]},{"@type":"WebSite","@id":"https:\/\/jdhitsolutions.com\/blog\/#website","url":"https:\/\/jdhitsolutions.com\/blog\/","name":"The Lonely Administrator","description":"Practical Advice for the Automating IT Pro","publisher":{"@id":"https:\/\/jdhitsolutions.com\/blog\/#\/schema\/person\/d0258030b41f07fd745f4078bdf5b6c9"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/jdhitsolutions.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/jdhitsolutions.com\/blog\/#\/schema\/person\/d0258030b41f07fd745f4078bdf5b6c9","name":"Jeffery Hicks","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/832ae5d438fdcfc1420d720cd1991307927de8a0b12f2342e81c30f773e21098?s=96&d=wavatar&r=pg","url":"https:\/\/secure.gravatar.com\/avatar\/832ae5d438fdcfc1420d720cd1991307927de8a0b12f2342e81c30f773e21098?s=96&d=wavatar&r=pg","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/832ae5d438fdcfc1420d720cd1991307927de8a0b12f2342e81c30f773e21098?s=96&d=wavatar&r=pg","caption":"Jeffery Hicks"},"logo":{"@id":"https:\/\/secure.gravatar.com\/avatar\/832ae5d438fdcfc1420d720cd1991307927de8a0b12f2342e81c30f773e21098?s=96&d=wavatar&r=pg"}}]}},"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_likes_enabled":true,"jetpack-related-posts":[{"id":2697,"url":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2697\/powershell-console-graphing-revised\/","url_meta":{"origin":2689,"position":0},"title":"PowerShell Console Graphing Revised","author":"Jeffery Hicks","date":"January 11, 2013","format":false,"excerpt":"Many of you have been having fun with my PowerShell Console Graphing tool I posted the other day. But I felt the need to make one more major tweak. I wanted to have the option for conditional formatting. That is, display graphed entries with high values in one color, medium\u2026","rel":"","context":"In &quot;PowerShell&quot;","block_context":{"text":"PowerShell","link":"https:\/\/jdhitsolutions.com\/blog\/category\/powershell\/"},"img":{"alt_text":"out-consolegraph-3","src":"https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/out-consolegraph-3-1024x816.png?resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/out-consolegraph-3-1024x816.png?resize=350%2C200 1x, https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/out-consolegraph-3-1024x816.png?resize=525%2C300 1.5x"},"classes":[]},{"id":449,"url":"https:\/\/jdhitsolutions.com\/blog\/powershell\/449\/drive-report-console-chart\/","url_meta":{"origin":2689,"position":1},"title":"Drive Report Console Chart","author":"Jeffery Hicks","date":"October 15, 2009","format":false,"excerpt":"In thinking about some of my recent posts, I realize I should make clear that these scripts and functions are not necessarily good PowerShell examples. They don\u2019t take advantage of objects and the pipeline. They are single purpose and one-dimensional. Not that there\u2019s anything wrong with that. My recent examples,\u2026","rel":"","context":"In &quot;PowerShell&quot;","block_context":{"text":"PowerShell","link":"https:\/\/jdhitsolutions.com\/blog\/category\/powershell\/"},"img":{"alt_text":"drivereport screenshot","src":"https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2009\/10\/drivereport_thumb.png?resize=350%2C200","width":350,"height":200},"classes":[]},{"id":2679,"url":"https:\/\/jdhitsolutions.com\/blog\/powershell\/2679\/graphing-with-the-powershell-console\/","url_meta":{"origin":2689,"position":2},"title":"Graphing with the PowerShell Console","author":"Jeffery Hicks","date":"January 9, 2013","format":false,"excerpt":"I've written before about using the PowerShell console as a graphing tool, primarily using Write-Host. Most of what I've published before were really proof of concept. I decided to try and come up with a more formal and re-usable tool that could create a horizontal bar graph based on a\u2026","rel":"","context":"In &quot;PowerShell&quot;","block_context":{"text":"PowerShell","link":"https:\/\/jdhitsolutions.com\/blog\/category\/powershell\/"},"img":{"alt_text":"out-consolegraph-1","src":"https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/out-consolegraph-1-1024x735.png?resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/out-consolegraph-1-1024x735.png?resize=350%2C200 1x, https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/out-consolegraph-1-1024x735.png?resize=525%2C300 1.5x"},"classes":[]},{"id":2044,"url":"https:\/\/jdhitsolutions.com\/blog\/scripting\/2044\/maximizing-the-powershell-console-title-bar\/","url_meta":{"origin":2689,"position":3},"title":"Maximizing the PowerShell Console Title Bar","author":"Jeffery Hicks","date":"January 31, 2012","format":false,"excerpt":"A few days ago Boe Prox posted some very nifty PowerShell modules for using the title bar as a ticker for RSS feeds like the weather. I thought this was an awesome idea and an easy way to take advantage of what would otherwise be unused screen space. I was\u2026","rel":"","context":"In &quot;PowerShell v2.0&quot;","block_context":{"text":"PowerShell v2.0","link":"https:\/\/jdhitsolutions.com\/blog\/category\/powershell-v2-0\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2012\/01\/console-title-sysstat-300x85.png?resize=350%2C200","width":350,"height":200},"classes":[]},{"id":2704,"url":"https:\/\/jdhitsolutions.com\/blog\/scripting\/2704\/powershell-graphing-with-out-gridview\/","url_meta":{"origin":2689,"position":4},"title":"PowerShell Graphing with Out-Gridview","author":"Jeffery Hicks","date":"January 14, 2013","format":false,"excerpt":"I've received a lot of interest for my last few posts on graphing with the PowerShell console. But I decided I could add one more feature. Technically it might have made more sense to turn this into a separate function, but I decided to simply modify the last version of\u2026","rel":"","context":"In &quot;Powershell 3.0&quot;","block_context":{"text":"Powershell 3.0","link":"https:\/\/jdhitsolutions.com\/blog\/category\/powershell-3-0\/"},"img":{"alt_text":"out-consolegraph-gv","src":"https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/out-consolegraph-gv-1024x548.png?resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/out-consolegraph-gv-1024x548.png?resize=350%2C200 1x, https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2013\/01\/out-consolegraph-gv-1024x548.png?resize=525%2C300 1.5x"},"classes":[]},{"id":4723,"url":"https:\/\/jdhitsolutions.com\/blog\/powershell\/4723\/a-powershell-new-year\/","url_meta":{"origin":2689,"position":5},"title":"A PowerShell New Year","author":"Jeffery Hicks","date":"December 31, 2015","format":false,"excerpt":"First off, let me thank all of you for your support and interest in my work this past year. Without it I'd be another old man sitting in his bathrobe talking to himself. I hope I can keep your interest in 2016. To wrap up the year and to bring\u2026","rel":"","context":"In &quot;Miscellaneous&quot;","block_context":{"text":"Miscellaneous","link":"https:\/\/jdhitsolutions.com\/blog\/category\/miscellaneous\/"},"img":{"alt_text":"Champagne_glasses","src":"https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2015\/12\/Champagne_glasses_thumb.png?resize=350%2C200","width":350,"height":200},"classes":[]}],"_links":{"self":[{"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/2689","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/comments?post=2689"}],"version-history":[{"count":0,"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/2689\/revisions"}],"wp:attachment":[{"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/media?parent=2689"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/categories?post=2689"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/tags?post=2689"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}