{"id":1061,"date":"2011-01-17T12:24:01","date_gmt":"2011-01-17T17:24:01","guid":{"rendered":"http:\/\/jdhitsolutions.com\/blog\/?p=1061"},"modified":"2011-01-17T12:24:01","modified_gmt":"2011-01-17T17:24:01","slug":"we-pause-a-moment","status":"publish","type":"post","link":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/","title":{"rendered":"We Pause a Moment"},"content":{"rendered":"<p>Most of the time when running a PowerShell script or series of commands you want to blast your way through. But there might be times where you want to pause script execution. Perhaps to display an informational message or to simply pace execution. In my work as a trainer and speaker I often use the famous Start-Demo script to walk through demo scripts. But you may not have that function or it doesn't make sense to use in the context of your script. For those situations you can use my Set-Pause function.<!--more--><\/p>\n<p>[cc lang=\"PowerShell\"]<br \/>\nFunction Set-Pause {<br \/>\n Param(<br \/>\n  [Parameter(Position=0)]<br \/>\n  [string]$Message=\"Press any key to continue...\",<\/p>\n<p>  [ValidateSet(\"Black\",\"DarkMagenta\",\"DarkRed\",\"DarkBlue\",<br \/>\n    \"DarkGreen\",\"DarkCyan\",\"DarkYellow\",\"Red\",<br \/>\n    \"Blue\",\"Green\",\"Cyan\",\"Magenta\",\"Yellow\",<br \/>\n    \"DarkGray\",\"Gray\",\"White\" )]<br \/>\n  [string]$ForegroundColor=\"Green\",<\/p>\n<p>  [ValidateScript({$_ -gt 0})]<br \/>\n  [Alias(\"seconds\")]<br \/>\n  [int32]$Sleep,<\/p>\n<p>  [Alias(\"cls\")]<br \/>\n  [switch]$Clear<br \/>\n  )<\/p>\n<p>    Write-Host $Message -foregroundcolor $foregroundcolor<\/p>\n<p>    #pause for specified number of seconds<br \/>\n    if ($Sleep)<br \/>\n    {<br \/>\n        Start-Sleep -Seconds $sleep<br \/>\n    }<br \/>\n    else<br \/>\n    {<br \/>\n        #wait for a key press<br \/>\n        $Running=$true<\/p>\n<p>        While ($Running)<br \/>\n        {<br \/>\n    \t if ($host.ui.RawUi.KeyAvailable) {<br \/>\n             $key = $host.ui.RawUI.ReadKey(\"NoEcho,IncludeKeyDown\")<br \/>\n                if ($key) {<br \/>\n                 $Running=$False<br \/>\n                }<br \/>\n          }<br \/>\n          sleep -millisecond 100<br \/>\n        } #end While<br \/>\n    }<\/p>\n<p>    if ($Clear)<br \/>\n    {<br \/>\n        Clear-Host<br \/>\n    }<br \/>\n} #end function<br \/>\n[\/cc]<br \/>\nThis function uses Write-Host to display a colored message to the console. I take advantage of the foregroundcolor so that the pause prompt, isn't co-mingled with your PowerShell output. You can use same parameter with my function to change the value. The default is Green.<\/p>\n<p>The default pause behavior is to wait for the user to press any key. This is accomplished by checking the KeyAvailable property from the host's RawUI property.<br \/>\n[cc lang=\"PowerShell\"]<br \/>\nif ($host.ui.RawUi.KeyAvailable) {<br \/>\n             $key = $host.ui.RawUI.ReadKey(\"NoEcho,IncludeKeyDown\")<br \/>\n                if ($key) {<br \/>\n                 $Running=$False<br \/>\n                }<br \/>\n          }<br \/>\n[\/cc]<br \/>\nAs such, this won't work in the ISE and I can't vouch it will work with other PowerShell hosts. Although it will work with the alternative behavior using the -Sleep parameter. With this parameter you can specify a number of seconds to pause, after which time execution continues. The other option is to use -Clear, which will clear the screen after every prompt. Finally, the script file with the function also defines an alias, Pause.<\/p>\n<p>Here's an example.<br \/>\n<a href=\"http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2011\/01\/pause-example.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2011\/01\/pause-example-1024x517.png\" alt=\"\" title=\"pause-example\" width=\"640\" height=\"323\" class=\"aligncenter size-large wp-image-1063\" srcset=\"https:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2011\/01\/pause-example-1024x517.png 1024w, https:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2011\/01\/pause-example-300x151.png 300w, https:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2011\/01\/pause-example.png 1144w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/a><\/p>\n<p>Download <a href='http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2011\/01\/set-pause.txt' Target=\"_blank\">Set-Pause.ps1<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Most of the time when running a PowerShell script or series of commands you want to blast your way through. But there might be times where you want to pause script execution. Perhaps to display an informational message or to simply pace execution. In my work as a trainer and speaker I often use the&#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":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[4,75,8],"tags":[32,534,101],"class_list":["post-1061","post","type-post","status-publish","format-standard","hentry","category-powershell","category-powershell-v2-0","category-scripting","tag-functions","tag-powershell","tag-write-host"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.5 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>We Pause a Moment &#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\/1061\/we-pause-a-moment\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"We Pause a Moment &#8226; The Lonely Administrator\" \/>\n<meta property=\"og:description\" content=\"Most of the time when running a PowerShell script or series of commands you want to blast your way through. But there might be times where you want to pause script execution. Perhaps to display an informational message or to simply pace execution. In my work as a trainer and speaker I often use the...\" \/>\n<meta property=\"og:url\" content=\"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/\" \/>\n<meta property=\"og:site_name\" content=\"The Lonely Administrator\" \/>\n<meta property=\"article:published_time\" content=\"2011-01-17T17:24:01+00:00\" \/>\n<meta property=\"og:image\" content=\"http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2011\/01\/pause-example-1024x517.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=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/1061\\\/we-pause-a-moment\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/1061\\\/we-pause-a-moment\\\/\"},\"author\":{\"name\":\"Jeffery Hicks\",\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/#\\\/schema\\\/person\\\/d0258030b41f07fd745f4078bdf5b6c9\"},\"headline\":\"We Pause a Moment\",\"datePublished\":\"2011-01-17T17:24:01+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/1061\\\/we-pause-a-moment\\\/\"},\"wordCount\":371,\"commentCount\":1,\"publisher\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/#\\\/schema\\\/person\\\/d0258030b41f07fd745f4078bdf5b6c9\"},\"image\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/1061\\\/we-pause-a-moment\\\/#primaryimage\"},\"thumbnailUrl\":\"http:\\\/\\\/jdhitsolutions.com\\\/blog\\\/wp-content\\\/uploads\\\/2011\\\/01\\\/pause-example-1024x517.png\",\"keywords\":[\"functions\",\"PowerShell\",\"Write-Host\"],\"articleSection\":[\"PowerShell\",\"PowerShell v2.0\",\"Scripting\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/1061\\\/we-pause-a-moment\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/1061\\\/we-pause-a-moment\\\/\",\"url\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/1061\\\/we-pause-a-moment\\\/\",\"name\":\"We Pause a Moment &#8226; The Lonely Administrator\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/1061\\\/we-pause-a-moment\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/1061\\\/we-pause-a-moment\\\/#primaryimage\"},\"thumbnailUrl\":\"http:\\\/\\\/jdhitsolutions.com\\\/blog\\\/wp-content\\\/uploads\\\/2011\\\/01\\\/pause-example-1024x517.png\",\"datePublished\":\"2011-01-17T17:24:01+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/1061\\\/we-pause-a-moment\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/1061\\\/we-pause-a-moment\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/1061\\\/we-pause-a-moment\\\/#primaryimage\",\"url\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/wp-content\\\/uploads\\\/2011\\\/01\\\/pause-example.png\",\"contentUrl\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/wp-content\\\/uploads\\\/2011\\\/01\\\/pause-example.png\",\"width\":\"1144\",\"height\":\"578\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/powershell\\\/1061\\\/we-pause-a-moment\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"PowerShell\",\"item\":\"https:\\\/\\\/jdhitsolutions.com\\\/blog\\\/category\\\/powershell\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"We Pause a Moment\"}]},{\"@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":"We Pause a Moment &#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\/1061\/we-pause-a-moment\/","og_locale":"en_US","og_type":"article","og_title":"We Pause a Moment &#8226; The Lonely Administrator","og_description":"Most of the time when running a PowerShell script or series of commands you want to blast your way through. But there might be times where you want to pause script execution. Perhaps to display an informational message or to simply pace execution. In my work as a trainer and speaker I often use the...","og_url":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/","og_site_name":"The Lonely Administrator","article_published_time":"2011-01-17T17:24:01+00:00","og_image":[{"url":"http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2011\/01\/pause-example-1024x517.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":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/#article","isPartOf":{"@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/"},"author":{"name":"Jeffery Hicks","@id":"https:\/\/jdhitsolutions.com\/blog\/#\/schema\/person\/d0258030b41f07fd745f4078bdf5b6c9"},"headline":"We Pause a Moment","datePublished":"2011-01-17T17:24:01+00:00","mainEntityOfPage":{"@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/"},"wordCount":371,"commentCount":1,"publisher":{"@id":"https:\/\/jdhitsolutions.com\/blog\/#\/schema\/person\/d0258030b41f07fd745f4078bdf5b6c9"},"image":{"@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/#primaryimage"},"thumbnailUrl":"http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2011\/01\/pause-example-1024x517.png","keywords":["functions","PowerShell","Write-Host"],"articleSection":["PowerShell","PowerShell v2.0","Scripting"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/","url":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/","name":"We Pause a Moment &#8226; The Lonely Administrator","isPartOf":{"@id":"https:\/\/jdhitsolutions.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/#primaryimage"},"image":{"@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/#primaryimage"},"thumbnailUrl":"http:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2011\/01\/pause-example-1024x517.png","datePublished":"2011-01-17T17:24:01+00:00","breadcrumb":{"@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/#primaryimage","url":"https:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2011\/01\/pause-example.png","contentUrl":"https:\/\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2011\/01\/pause-example.png","width":"1144","height":"578"},{"@type":"BreadcrumbList","@id":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1061\/we-pause-a-moment\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"PowerShell","item":"https:\/\/jdhitsolutions.com\/blog\/category\/powershell\/"},{"@type":"ListItem","position":2,"name":"We Pause a Moment"}]},{"@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":1404,"url":"https:\/\/jdhitsolutions.com\/blog\/scripting\/1404\/start-typeddemo\/","url_meta":{"origin":1061,"position":0},"title":"Start-TypedDemo","author":"Jeffery Hicks","date":"May 3, 2011","format":false,"excerpt":"As you know, I do a lot of presenting and training. Normally I use the ubiquitous Start-Demo function to run through a demo list of commands. Most of this time this works just fine. But when I'm doing videos, especially for a video project, I want the viewer to focus\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":"","width":0,"height":0},"classes":[]},{"id":4445,"url":"https:\/\/jdhitsolutions.com\/blog\/powershell\/4445\/simulating-a-powershell-demo\/","url_meta":{"origin":1061,"position":1},"title":"Simulating a PowerShell Demo","author":"Jeffery Hicks","date":"July 13, 2015","format":false,"excerpt":"A number of years ago I published my version of a Start-Demo script. In my version, I can create a text file with all of the commands I want to run. It might look like this: Get-Date get-ciminstance win32_logicaldisk | select DeviceID,Size,Freespace :: get-service | where {$_.status -eq 'running'} |\u2026","rel":"","context":"In &quot;PowerShell&quot;","block_context":{"text":"PowerShell","link":"https:\/\/jdhitsolutions.com\/blog\/category\/powershell\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":3939,"url":"https:\/\/jdhitsolutions.com\/blog\/powershell\/3939\/press-powershell-pause-to-continue\/","url_meta":{"origin":1061,"position":2},"title":"Press PowerShell Pause to Continue","author":"Jeffery Hicks","date":"August 8, 2014","format":false,"excerpt":"Everyone once in a while I come across a PowerShell script that behaves like an old-fashioned batch file. Not that there's anything wrong with that, but often these types of scripts put in a pause at the end of script so you can see that it finished. You might have\u2026","rel":"","context":"In &quot;CommandLine&quot;","block_context":{"text":"CommandLine","link":"https:\/\/jdhitsolutions.com\/blog\/category\/commandline\/"},"img":{"alt_text":"talkbubble","src":"https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2011\/10\/talkbubble.png?resize=350%2C200","width":350,"height":200},"classes":[]},{"id":1220,"url":"https:\/\/jdhitsolutions.com\/blog\/powershell\/1220\/friday-fun-virtual-demos\/","url_meta":{"origin":1061,"position":3},"title":"Friday Fun Virtual Demos","author":"Jeffery Hicks","date":"March 11, 2011","format":false,"excerpt":"I've been prepping my demo scripts for Techmentor using the ubiquitous Start-Demo, and realized I could take things further. I mean, why do I have to do all the talking? Windows 7 has a terrific text to speech engine so why not take advantage of it. With a little work\u2026","rel":"","context":"In &quot;Conferences&quot;","block_context":{"text":"Conferences","link":"https:\/\/jdhitsolutions.com\/blog\/category\/conferences\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":1473,"url":"https:\/\/jdhitsolutions.com\/blog\/scripting\/1473\/friday-fun-start-typeddemo-v2\/","url_meta":{"origin":1061,"position":4},"title":"Friday Fun: Start-TypedDemo v2","author":"Jeffery Hicks","date":"May 27, 2011","format":false,"excerpt":"Not too long ago I posted a function I wrote for doing PowerShell demonstrations. My goal was to simulate a live interactive demo but without the typing so I could focus on explaining and not typing. The first version was a good start but I always had plans for a\u2026","rel":"","context":"In &quot;Friday Fun&quot;","block_context":{"text":"Friday Fun","link":"https:\/\/jdhitsolutions.com\/blog\/category\/friday-fun\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":5242,"url":"https:\/\/jdhitsolutions.com\/blog\/powershell\/5242\/another-powershell-todo-tool\/","url_meta":{"origin":1061,"position":5},"title":"Another PowerShell ToDo Tool","author":"Jeffery Hicks","date":"September 13, 2016","format":false,"excerpt":"Recently a reader, Matt Penny, shared a tip in a comment on one of my articles. He had a short and simple PowerShell function that he used to insert ToDo commands into his Pester test scripts. Although you could easily use it for other PowerShell work. Of course, I am\u2026","rel":"","context":"In &quot;PowerShell&quot;","block_context":{"text":"PowerShell","link":"https:\/\/jdhitsolutions.com\/blog\/category\/powershell\/"},"img":{"alt_text":"image","src":"https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2016\/09\/image_thumb-1.png?resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2016\/09\/image_thumb-1.png?resize=350%2C200 1x, https:\/\/i0.wp.com\/jdhitsolutions.com\/blog\/wp-content\/uploads\/2016\/09\/image_thumb-1.png?resize=525%2C300 1.5x"},"classes":[]}],"_links":{"self":[{"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/1061","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=1061"}],"version-history":[{"count":0,"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/1061\/revisions"}],"wp:attachment":[{"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/media?parent=1061"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/categories?post=1061"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jdhitsolutions.com\/blog\/wp-json\/wp\/v2\/tags?post=1061"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}