Microsoft Paint has been bundled with the Windows operating system since the 1990s and, over the years, has become a more well-rounded graphics design application. One of the features added since the early days is the ability to erase only a certain color from an image, replacing it with a color of your choice. You can learn how to use the "color replacement" function in just a few steps.
Select the "eraser" tool from the toolbox on the left-hand side of the screen.
Click on the primary color box and select the color that you'd like to erase, then click on the secondary color box and choose the color you'd like to replace the primary color with. For example, if you're working with a white background and you'd like to replace black with white, you should set black as the primary color and white as the secondary color.
Hold down the right mouse button and sweep over the image with your mouse pointer. The primary color will start to disappear and be replaced with the secondary color.
Click "File" and "Save" to save the changes you've made to your image.