© The Author(s), under exclusive license to APress Media, LLC, part of Springer Nature 2021
I. WatersPowerShell for Beginnershttps://doi.org/10.1007/978-1-4842-7064-6_12

12. Getting Colorful

Ian Waters1  
(1)
Bexhill, UK
 

In this chapter, you are going to learn how to change the color of text written out to the console. We will look at all of the text color options available including background colors and then explore how to customize the background color of the PowerShell console itself. Adding a splash of color to your scripts can help make the text more readable and specific items stand out more. If you need to display an error message, then make it red. If a script has successfully performed a task, then let the user know by using some green text. ...

Get PowerShell for Beginners: Learn PowerShell 7 Through Hands-On Mini Games now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.