- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
How to change the color of the PowerShell ISE editor using command?
To change the color of the ISE Editor, we need to use $psISE cmdlet which is only available for the ISE editor.
Now in the ISE editor, we have many colors some are visible (ScriptPane color, Console Color, etc) and some appear while executing a script (Error, Warning, Verbose). These properties are as below.
ErrorForegroundColor : #FFFF9494 ErrorBackgroundColor : #00FFFFFF WarningForegroundColor : #FFFF8C00 WarningBackgroundColor : #00FFFFFF VerboseForegroundColor : #FF00FFFF VerboseBackgroundColor : #00FFFFFF DebugForegroundColor : #FF00FFFF DebugBackgroundColor : #00FFFFFF ConsolePaneBackgroundColor : #FF000080 ConsolePaneTextBackgroundColor : #FF012456 ConsolePaneForegroundColor : #FFF5F5F5 ScriptPaneBackgroundColor : #FFFFFFFF ScriptPaneForegroundColor : #FF000000
Lef side is the particular color attribute and the right side is the color name in the code. To set the Console Background color, we can use the following command, and immediately console background color will change to red.
$psISE.Options.ConsolePaneBackgroundColor = 'Red'
Output
Similarly, to change the script pane background color,
$psISE.Options.ScriptPaneBackgroundColor = 'Black'
Output
Similarly, you can set debug mode color, error, warning, verbose color, etc.
If you have messed color in ISE and want to restore back then don’t worry, there is an option DefaultOptions in the $PSISE cmdlet, Options property and there you can find the original color.
$psISE.Options.DefaultOptions
We can restore the colors using the below command.
$psISE.Options.ScriptPaneBackgroundColor = '#FFFFFFFF'
- Related Articles
- How to change PowerShell ISE font Size using command?
- How to change the Title of the console using PowerShell command?
- How to change the Foreground color or Font color of the console using PowerShell?
- How to change the background color of the font in PowerShell?
- How to change the size of the Console using PowerShell?
- How to change the background color using jQuery?
- How to change the Drive letter using PowerShell?
- How to change the size of the Azure VM using PowerShell?
- How to change the local disk name using PowerShell?
- How to change the Azure tag value using PowerShell?
- How to change the font color of a text using JavaScript?
- How to change the face color of a plot using Matplotlib?
- How to change the color of points for ggplot2 scatterplot using color brewer in R?
- How to use the Timeout command in PowerShell?
- How to use the tree command in PowerShell?
