Pips Calculation Solution for All Trading Instruments

 

Gents,

I am a bit scatter brain at the moment. I would like your input on the code for pips calculation for all trading instruments. Please let me know if you think that it will not work for all brokers.


   if (Digits % 2 == 1)   { pips  = Point*10; } 
   else   {  pips  = Point;    }

      sOP = "BUY";
      clOP = Aqua;
      market_price = Ask;
      market_SL = Ask - (StopLoss1*pips);
      market_TP = Ask + (TakeProfit1*pips);


Reason: