In the pre-existing code, the HTML file background colour has been set like this:
file+="<table width=\"95%\" align=\"center\" style=\"background : #"+
HTML_REPORT_COLOR_2+"; border : 1px solid #000000\">";
file+="Wrong colour for driver has been chosen . The correct tag is Green";
file+="<br/><br/>";
I want to change the wrong word which is presently in black to red. The right way to go about using the fonts tag, but how do I use it here, as this is a Java code. I tried feeding it to the file variable, but “#” is giving me an error.
Current
Wrap the word “Wrong” in a span tag, like this:
If you have access to the CSS of the document, add this declaration:
If you don’t have access to the CSS, make the
spanelement look like this, instead:Previous
If I’m correctly understanding what you’re trying to do, you need to change the hexadecimal value of
HTML_REPORT_COLOR_2from000000or000toFF0000orF00.That should be the solution, unless I’m mis-understanding your problem.