I have made an EA with a function to move "stop loss", I set two parameters for this function"extern int Move_Stop_Small=5,Move_Stop_Big=10;", when I test it many times and modified these two parameters many times, once I set "extern int Move_Stop_Small=10,Move_Stop_Big=20;". what is surprising is that now I set these two parameters whatever values,such as "extern int Move_Stop_Small=5,Move_Stop_Big=10;", “extern int Move_Stop_Small=10,Move_Stop_Big=30;”， and so on; when I print these two parameters, always show"Move_Stop_Small is 10, Move_Stop_Big is 20". I don't know why?
now I delete all other codes except very few codes as below: when I copy this codes to another EA which I create newly, it run well; but always wrong in the EA which I modified. why?
extern int Move_Stop_Small=5,Move_Stop_Big=10;
I suspect somethings wrong in my MT4 platform; so few codes can't shelter any bug I think.
above code never show value "20", but these few codes run and get the result Move_Stop_Big is 20, so strange.
Thank you ubzen.
yes just as you said, I it" within the strategy-tester ... ".
I believe what you said is correct, but maybe not all.
Just now I copied fold "expert" from the MT4 and uninstall the MT4, then I re-install MT4 and copied the fold "expert" into the new MT4.
then I run previous EA, all is Ok.
I change these two parameters again and compile(not hit reset_button), then run the EA, these two parameters have changed from before.
For my last MT4, I think the parameters' value, 10 and 20, must have been remembered in somewhere.
I have test again.
when I write an indicator which with some "extern" variables and then write an EA which call this indicator by iCustom(Null,0,"Indicator",n1,n2,n3,0,0), after that I test it by tester.
most time when I changed n1,n2 and n3's values, and recompiling then I test it in tester, I find n1,n2,and n3's new values have been transfered to this indicator.
but I never reset anything. so maybe