Last time we looked at the new script editor features. Now we will take a look at the new Function Explorer as well as other additions.
The new Function Explorer displays a list of all the functions and events within the current script file:
If you are working within a Project, the available functions declared in other files will also be displayed.
Navigating with the Function Explorer:
Just by a simple double click on the function or event, it will take you directly to the declaration of the function. This becomes invaluable when dealing with scripts with a large number of functions.
Function Explorer Context Menu:
The context menu allows to do the following:
Go to Declaration
Goes to the function’s declaration (same as double clicking on the function name). If the function is in another project file, then it will navigate to that file.
Inserts a call to the function.
Copies the whole function definition to the clipboard.
Renames the function including all references to the function. Within Projects, it will also update references made to the function by other project files. If you rename an event, all the controls that reference the event will also be updated. As you can see this can be a big time saver when dealing with larger scripts.
Before Function Renaming:
After Function Renaming:
Other Additions and Changes:
PowerShell Studio offers many other performance improvement and other numerous minor additions, changes, and keyboard shortcuts that are not listed here. The following is some more prominent miscellaneous additions you will find:
Enhanced Console Input Line
The console now has an enhanced input line that offers the same PrimalSense support as the script editor. You have the option to enable or disable this feature.
Project File Renaming:
When renaming project files, reference functions will be updated accordingly through out the project files.
Before Project File Renaming:
After Project File Renaming:
Explicit Support For PowerShell Remoting:
PowerShell Studio now has explicit support for PowerShell Remoting. Use the “Run Remotely” option under the Run Menu:
Next you will be presented with a dialog to enter the remote credentials:
And finally the script will run on the remote computer.
Note: This feature requires that remoting be enabled on the target system.
PowerShell Studio 2012 also supports Remote Debugging. This feature will be discussed in a separate article.
Just like PrimalScript 2012, PowerShell Studio added support for trace points. See the PrimalScript 2012: What’s New? articles for more details.
All in all, you will find that SAPIEN PowerShell Studio 2012 is a major improvement over its predecessor.