How to change the color of text in EA

 

Hi, can anyone tell me how to change the color of text that appears as a comment in an EA?

Best bregards

 
fxwealth:
Hi, can anyone tell me how to change the color of text that appears as a comment in an EA? Best bregards

You have to change it in the code of the MQ4 file.

 

Hi, yes am aware of that. Would like to change the color in the following line of code

Comm=Comm+" ("+DoubleToStr(High-kH*H2,j)+") broken at "+DoubleToStr(k,j)+", uptarget:\n";

Many thanks

 

you may have to experiment with objects to get some color

int init(){

return(0);}

int deinit()

{

ObjectDelete("com1");

return(0);}

int start()

{

string text="I like Monkeys";

ObjectCreate("com1", OBJ_LABEL, 0, 0, 0);

ObjectSetText("com1",text, 6, "Arial Bold", Lime);

ObjectSet("com1", OBJPROP_CORNER,0);

ObjectSet("com1", OBJPROP_XDISTANCE, 2);

ObjectSet("com1", OBJPROP_YDISTANCE, 43);
 

Thanks Lowphat will try it out

Reason: