( integer/(integer+integer) ) always gives zero in Mt5

 

Hi... Mt4 to Mt5 conversion... where the integers are variable counts such as, if(varA/(VarA+VarB) >.95) {VarC=-5;}

    ( integer/(integer+integer) )

 Or (int)Mathround (integer/(integer+integer))

      always gives zero in Mt5, How do i get the double solution?

 

   

 

You could try

if(1.0*varA/(VarA+VarB) >.95)

 
Keith Watford:

You could try

if(1.0*varA/(VarA+VarB) >.95)

or 

if((double)varA/(VarA+VarB) >.95) {VarC=-5;}
 
They both work, thanks Keith and Alain...
 
 
Keith Watford:

You could try

if(1.0*varA/(VarA+VarB) >.95)

This is the best thing i have read today

Reason: