How to use color instruction in dos
This article mainly introduces how to use the color instruction in dos, which has a certain reference value, interested friends can refer to, I hope you can learn a lot after reading this article, let the editor take you to understand it.
Color
For the current session, change the foreground and background color of the command prompt window. If used without parameters, color restores the foreground and background colors of the command prompt window to the default colors.
Grammar
Color [fb]
Parameters.
Fb
Set the foreground f and background g colors. The following table lists the hexadecimal numbers that can be used as values for f and g. Value color
0 black
1 blue
2 green
3 Lake blue
4 red
5 purple
6 yellow
7 White
8 Gray
9 light blue
A light green
B shallow water green
C light red
D light purple
E light yellow
F bright white
/?
Displays help at the command prompt.
Annotation
To set the default command prompt window color, click the upper-left corner of the command prompt window, click default, click the Color tab, and then click the color you want to use for screen text and screen background.
For the current session, you can use cmd / t:fb to change the color of the command prompt window.
If the foreground and background colors are the same, the color command sets ERRORLEVEL to 1.
Example
To set the foreground color of the command prompt window to red and its background color to white, type:
Color FC
Thank you for reading this article carefully. I hope the article "how to use color instructions in dos" shared by the editor will be helpful to you. At the same time, I also hope you will support us and pay attention to the industry information channel. More related knowledge is waiting for you to learn!