troubleshooting Question

Excel VBA - Setting same font color like background

Avatar of csehz
csehzFlag for Hungary asked on
VBAMicrosoft ExcelMicrosoft Office
7 Comments2 Solutions14 ViewsLast Modified:
Dear Experts,

Actually having a specific scenario, I would need to have putting an 'x' character in all colored background cells in range A1 and G7 by VBA, but with exactly the same font color as the background found:

There might be not only 4 colors in the scenario, so searching for a VBA logic which always putting the same color text as the background color found.

Could you please advise that which VBA code could reach that target?

In the attached Excel file filled the cells manually, if the cell has the default white background then it should stay blank without putting any text

DifferentBGColorsInRange.xlsx DifferentBGColorsInRange.xlsx

Thanks in advance,
Join our community to see this answer!
Unlock 2 Answers and 7 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 2 Answers and 7 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros