In this tutorial, you will learn how to customize the actual ISE instead of the command shell in PowerShell 2.0.
If you have not already done so, click open Windows PowerShell ISE.
Much like the Windows PSH console has a $host variable that you can manipulate to access the console object, the ISE has a $psISE variable that lets you access the ISE host.
By using the $psISE variable, you can customize the color scheme of your ISE through the $psISE variable's options property.
In the command window of the ISE, type in:
You should come across a list that appears like so:
Changing the values on any one of these objects is quite simple. Remember that the period is possessive, so if we say, change the OutputPaneTextBackground a different color value, you will have to keep in mind that the property belongs to options property which belongs to the $psISE variable. At this point, something like the following line should come to mind:
ISE.options.OutputPaneTextBackground = "colorOfChoice"
Much like the PowerShell console default settings, you can put any one of these changes into your ISE profile script so that when it is launched, you have all the modifications you want.
A very short blurb but hopefully, it was useful! Everyone likes to have a bit of customization to their programs and if you use it often, why not! These options are made available to suit any and every individual who needs it. Join us next time for more tutorials! Till then…