{"id":13426,"date":"2017-02-28T08:00:27","date_gmt":"2017-02-28T16:00:27","guid":{"rendered":"https:\/\/www.sapien.com\/blog\/?p=13426"},"modified":"2017-02-28T09:05:14","modified_gmt":"2017-02-28T17:05:14","slug":"powershell-studio-2017-service-release-v5-4-136","status":"publish","type":"post","link":"https:\/\/dev.sapien.com\/blog\/2017\/02\/28\/powershell-studio-2017-service-release-v5-4-136\/","title":{"rendered":"PowerShell Studio 2017: Service Release v5.4.136"},"content":{"rendered":"<p>Today we released a new build of PowerShell Studio 2017 (v5.4.136).<\/p>\n<p>&nbsp;<\/p>\n<p>In this build, we went down the list and implemented several user-requested features.<\/p>\n<p>&nbsp;<\/p>\n<h2>General Features:<\/h2>\n<h3>Forwards and Backwards Navigation<\/h3>\n<p>We had several user requests for this feature. The new navigation feature allows you to jump back to previously visited documents or previous locations within the same document.<\/p>\n<p>Ribbon-&gt;Home-&gt;Navigation<\/p>\n<p><a href=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Ribbon-Navigate.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"Ribbon Navigate\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"Ribbon Navigate\" src=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Ribbon-Navigate_thumb.png\" width=\"376\" height=\"148\"><\/a><\/p>\n<table class=\"nicetable\" cellspacing=\"0\" cellpadding=\"2\" width=\"50%\" border=\"0\">\n<tbody>\n<tr>\n<td valign=\"top\" width=\"139\"><strong>Navigate Forward<\/strong><\/td>\n<td valign=\"top\" width=\"124\">[Ctrl + Shift + +]<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"139\"><strong>Navigate Backward<\/strong><\/td>\n<td valign=\"top\" width=\"124\">[Ctrl + Shift + -]<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>If you use the <strong>Go to Definition<\/strong> feature, it will take you to the declaration of a function. Previously, you had to scroll back to find where you left off, but now you can press the<strong> Navigate Backwards<\/strong> button and PowerShell Studio will jump back to your previous line, so you can continue to work uninterrupted. Navigation will also take you back to the previous document when you open or click on different document.<\/p>\n<p>&nbsp;<\/p>\n<h2>Editor Features:<\/h2>\n<p>&nbsp;<\/p>\n<h3>Splatting<\/h3>\n<p>Another popular request was to add the ability to splat commands.&nbsp; <\/p>\n<blockquote>\n<p><strong><em>What is splatting?<\/em><\/strong><br \/><em>Splatting is a method of passing parameter values to a command via a hash table or an array.<\/em><\/p>\n<\/blockquote>\n<p>You can \u201csplat\u201d your commands by using the editor context menu.<\/p>\n<p><a href=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Splat-Command-Content-Menu.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"Splat Command - Content Menu\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"Splat Command - Content Menu\" src=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Splat-Command-Content-Menu_thumb.png\" width=\"644\" height=\"278\"><\/a><\/p>\n<p>The splat command converts the command parameters into a hash table and passes the variable containing the hash table to the targeted command:<\/p>\n<p><a href=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Splatted-command.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"Splatted command\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"Splatted command\" src=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Splatted-command_thumb.png\" width=\"370\" height=\"158\"><\/a><\/p>\n<p>&nbsp;<\/p>\n<h3>Run Selection Resolving Functions<\/h3>\n<p>PowerShell Studio\u2019s internal host resets the runspace every time you run a script. As a result, functions declared outside the section (or even in another project file), will not be defined when you use the <strong>Run Selection<\/strong> command.&nbsp; <\/p>\n<p><a href=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Run-Selection-Error.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"Run Selection - Error\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"Run Selection - Error\" src=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Run-Selection-Error_thumb.png\" width=\"644\" height=\"310\"><\/a><\/p>\n<p>With this new feature, you no longer have to include the function definition in the selection when using the <strong>Run Selection<\/strong> command:<\/p>\n<p><a href=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Run-Selection-Success.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"Run Selection - Success\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"Run Selection - Success\" src=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Run-Selection-Success_thumb.png\" width=\"644\" height=\"294\"><\/a><\/p>\n<p>In a project context, PowerShell Studio will also automatically resolve functions defined in other project files.<\/p>\n<p>You have the option to disable this feature in Options-&gt;Editor:<\/p>\n<p><a href=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Options-Resolve-Functions.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"Options - Resolve Functions\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"Options - Resolve Functions\" src=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Options-Resolve-Functions_thumb.png\" width=\"612\" height=\"484\"><\/a><\/p>\n<p><font color=\"#800000\">Important: This option only applies to <strong>Run Selection<\/strong> and not to <strong>Run Selection in Console<\/strong>.<\/font><\/p>\n<p>&nbsp;<\/p>\n<h3>Using Namespaces<\/h3>\n<p>Windows PowerShell V5 introduced the using namespace directive:<\/p>\n<blockquote>\n<p>using namespace System.Drawing<\/p>\n<\/blockquote>\n<p>The using statement saves you from having to type the full name of a Type object. <\/p>\n<blockquote>\n<p>For example,<\/p>\n<p><pre lang=\"PowerShell\">[Color]<\/pre>\n<p>instead of:<\/p>\n<p><pre lang=\"PowerShell\">[System.Drawing.Color]<\/pre>\n<\/blockquote>\n<p>PowerShell Studio will now take into account the using namespace statement defined at the top of the document to correctly provide syntax coloring and PrimalSense support.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" title=\"PrimalSense - Namespaces\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"PrimalSense - Namespaces\" src=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/PrimalSense-Namespaces.png\" width=\"285\" height=\"250\"><\/p>\n<p>&nbsp;<\/p>\n<h3>PrimalSense \u2013 Common Parameters<\/h3>\n<p>PrimalSense will now display common parameters at the end of the PrimalSense list when the <strong>Sort parameters alphabetically<\/strong> option is disabled. This ensures that the command parameters take precedence over common parameters.<\/p>\n<p>&nbsp;<\/p>\n<h3>Function Builder and Wildcards<\/h3>\n<p>We added the option to set the SupportsWildcards attribute via the Function Builder\u2019s Parameter dialog:<\/p>\n<p><a href=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Parameter-Dialog.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"Parameter Dialog\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"Parameter Dialog\" src=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Parameter-Dialog_thumb.png\" width=\"570\" height=\"484\"><\/a><\/p>\n<pre lang=\"PowerShell\">function Get-Object\n{\n\tparam (\n\t\t[Parameter(Mandatory = $true)]\n\t\t[SupportsWildcards()]\n\t\t[string]\n\t\t$Name\n\t      )\n\n\t#TODO: Place script here\n}<\/pre>\n<h2>Project Features:<\/h2>\n<p>&nbsp;<\/p>\n<h3>Project Files \u2013 Shared PrimalSense<\/h3>\n<p>Setting the <strong>Shared<\/strong> property of a project file tells PowerShell Studio to provide PrimalSense for the functions defined in the file, across the whole project. Previously, this setting only worked if the <strong>Build<\/strong> property was set to <em>Include<\/em>. With this service release, you can do the same with ps1 project files with the <strong>Build<\/strong> property set to <em>Content<\/em>. <\/p>\n<p>This comes in handy when dealing with a module project where you dot source the files into the module programmatically and still get the benefit of PrimalSense when working with multiple content files.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" title=\"Project File Properties Shared\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"Project File Properties Shared\" src=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Project-File-Properties-Shared.png\" width=\"297\" height=\"210\"><\/p>\n<p>&nbsp;<\/p>\n<h3>Project Panel \u2013 Tooltip<\/h3>\n<p>When you hover over a file in the Project panel, it will now provide you with a tooltip containing the file path information.<\/p>\n<p><a href=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Project-Panel-Path-tooltip.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"Project Panel - Path tooltip\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"Project Panel - Path tooltip\" src=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Project-Panel-Path-tooltip_thumb.png\" width=\"567\" height=\"225\"><\/a><\/p>\n<p>&nbsp;<\/p>\n<h3>Improved Project Load Speeds<\/h3>\n<p>Not a new feature, but it is worth mentioning that this build improves the loading speed of large projects.<\/p>\n<p>&nbsp;<\/p>\n<h3>Rename Refactoring and Manifests<\/h3>\n<p>When you rename a function using refactoring, PowerShell Studio will now update the module project\u2019s manifest as well. <\/p>\n<p><a href=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Rename-Manifest.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"Rename Manifest\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"Rename Manifest\" src=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Rename-Manifest_thumb.png\" width=\"505\" height=\"484\"><\/a><\/p>\n<p>&nbsp;<\/p>\n<h2>Other Features:<\/h2>\n<h3>Tools Panel Content Menu<\/h3>\n<p>We added<strong> Bring to Front<\/strong> and <strong>Send to Back<\/strong> commands to the Tools panel\u2019s select list content menu:<\/p>\n<p><a href=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Tool-Box-Content-Menu.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"Tool Box - Content Menu\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"Tool Box - Content Menu\" src=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Tool-Box-Content-Menu_thumb.png\" width=\"306\" height=\"346\"><\/a><\/p>\n<p>Now without having to find the control in the designer itself, you can send it straight to the top using the <strong>Bring to Front<\/strong> command using the Tools panel.<\/p>\n<p>&nbsp;<\/p>\n<h3>New Packager Options<\/h3>\n<p>This build introduces two new packager options that relate to Script Block logging. <\/p>\n<h4><a href=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Script-Packager-Script-Block-Restriction.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"Script Packager Script Block Restriction\" style=\"border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px\" border=\"0\" alt=\"Script Packager Script Block Restriction\" src=\"https:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2017\/02\/Script-Packager-Script-Block-Restriction_thumb.png\" width=\"644\" height=\"419\"><\/a><\/h4>\n<h4>Do not execute if Script Block logging is enabled<\/h4>\n<p>When enabled, this option will prevent the executable from running when Script Block logging is enabled on the host machine. <\/p>\n<h4>Disable Script Block logging while running<\/h4>\n<p>When enabled, the packaged executable will disable Script Block logging when executing. This setting requires admin privileges in order to disable the logging.<br \/><font color=\"#800000\">Important: If the executable is unable to deactivate logging, it will continue to run, unless you enable the do not execute option above.<\/font><\/p>\n<p>&nbsp;<\/p>\n<p>These new options offer another layer of protection for scripts that contain sensitive information. <\/p>\n<p>&nbsp;<\/p>\n<h3>Silent Deactivation<\/h3>\n<p>The final feature added to this build is the command line option <strong>\/DEACTIVATE<\/strong> to silently deactivate your software:<\/p>\n<p><pre lang=\"PowerShell\">PowerShell Studio.exe \/DEACTIVATE<\/pre>\n<p>Note: The software will require internet access in order to deactivate a subscription number successfully.<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>Please continue providing your feedback. Many of the new features included in the service builds are suggestions from users like you. Therefore, if you have any suggestions or feature requests, please share them with us on our <a href=\"https:\/\/www.sapien.com\/forums\/viewforum.php?f=9\">Wish List and Feature Requests<\/a> forum.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Today we released a new build of PowerShell Studio 2017 (v5.4.136). &nbsp; In this build, we went down the list and implemented several user-requested features. &nbsp; General Features: Forwards and Backwards Navigation We had several user requests for this feature. The new navigation feature allows you to jump back to previously visited documents or previous [&hellip;]<\/p>\n","protected":false},"author":10,"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,"footnotes":""},"categories":[703,624,21],"tags":[28,1188,645,155],"class_list":["post-13426","post","type-post","status-publish","format-standard","hentry","category-powershell-studio","category-service-build","category-software-news","tag-powershell","tag-powershell-studio-2017","tag-service-build-2","tag-service-release"],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/posts\/13426","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/users\/10"}],"replies":[{"embeddable":true,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/comments?post=13426"}],"version-history":[{"count":15,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/posts\/13426\/revisions"}],"predecessor-version":[{"id":13449,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/posts\/13426\/revisions\/13449"}],"wp:attachment":[{"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/media?parent=13426"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/categories?post=13426"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/tags?post=13426"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}