Forum

having trouble converting double to int then back to double

ok some times it outputs something like 44.99999999 or 44.00000001 its like it has some small math error double m1_IRS = iRSI ( NULL , 1 , 14 , PRICE_CLOSE , 0 ); int temp1 = m1_IRS* 100 ; m1_IRS = temp1* 1 ; m1_IRS = m1_IRS/ 100 ; and one other thing i added 2 more indicator

trying to understand the code in rsi indacator

ok so im new to programing in mt4 so i don't know a lot of the functions yet but i think i understand most of it but i don't see where it adds the rsi value after the short name that gets displayed in the top left corner i also added a rigged up alarm there probably is a better way to do the timing

ObjectCreate keeps putting the obj_label in the wrong window

ok so the first ObjectCreate puts it in window 0 (main) and the second ObjectCreate puts it in the 2 i dont know why??? ObjectCreate ( "m5" , OBJ_LABEL , 0 , 0 , 0 ); ObjectSetText ( "m5" , "M5 " + iRSI ( NULL , 5 , 14 , PRICE_CLOSE , 0 )); ObjectSet ( "m5" , OBJPROP_CORNER , 0 );