get rid from warning : about PlotIndexGetInteger & PLOT_LINE_COLOR

hi ;

i use this line in my code and have a warning:


for(int c=0;c<CURRENCY_COUNT-1;c++)  Currency_color[c+1]=PlotIndexGetInteger(c,PLOT_LINE_COLOR);
       

and have this warning :  " possible loss of data due to type conversion  "

 

how can fix it ?

first try : https://www.mql5.com/en/forum/31130/unread#unread


and its done.

how can fix this warning for :

for(int c=0;c<CURRENCY_COUNT-1;c++)  Currency_color[c+1]=PlotIndexGetInteger(c,PLOT_LINE_COLOR);

and have this warning :  " possible loss of data due to type conversion  "

?

how can change color for indicator line & an object and they must have same color ?
how can change color for indicator line & an object and they must have same color ?
  • www.mql5.com
how can change color for indicator line & an object and they must have same color ? - - Category: general
Mehrdad Shiri:

hi ;

i use this line in my code and have a warning:

and have this warning :  " possible loss of data due to type conversion  "

 

how can fix it ?


for(int c=0;c<CURRENCY_COUNT-1;c++)  Currency_color[c+1]=(color)PlotIndexGetInteger(c,PLOT_LINE_COLOR);
Mehrdad Shiri :

hi ;

i use this line in my code and have a warning:

and have this warning :  " possible loss of data due to type conversion  "

 

how can fix it ?

What type has an array Currency_color []?
Alain Verleyen:

:-)

thank you.

Karputov Vladimir:
What type has an array Currency_color []?

thank you my friends.

problem solved with correction from alain.

thanks again.