Forum

Running backtesting multiple times slows down with each test

Hi, I have MT5. I've written a nice algo that works quite fast. I wrote a program to try different settings. It closes and opens MT5 on each run so I can change the settings. I can run it overnight, but after about half an hour of multiple tests it slows down so much I have to reboot my computer. In

Can't round a number "0.13"

I can't place an order because I get an error that there's too many digits in the quantity. I really hope someone can help me with this, because I can't run my algo at all whilst I have this persistent problem. For example, if I try double thisQty=(double)"0.13"; I always get 0.130000000000000004