muruku Posted September 22, 2010 Report Share Posted September 22, 2010 Dear fancy, take note the solid rock code I just scripted when inspiration came today.. The while (wild) loop force below clean up all open trades & pending orders when the MinProfit is hit.. happy coding... double Pips = TotalProfit(Magic); if (Pips >= MinProfit){ while(MyOrdersTotal(Magic) != 0){ CloseAllTrades(1, Magic); CloseAllTrades(2, Magic); DeletePendingOrders(Magic); } shady2500 1 Quote Link to comment Share on other sites More sharing options...
shady2500 Posted September 22, 2010 Report Share Posted September 22, 2010 This is the latest setting from muruku.... i use this on my live account start from today :D http://www.multiupload.com/YYJMQK9FB2 give thanks to muruku for his great setting :D Hi, thank you for sharing but when i tried to test it, it showed me this message 2010.09.22 15:38:25 Cannot open file 'C:\Program Files\FXDD Malta - MetaTrader 4\experts\indicators\ATR_Pips.ex4' on the GBPUSD,M15 although i am using i on the one hour and also i am 5digits. i even tried to look for this indicator couldn't find it. can you please help me? Regards, Quote Link to comment Share on other sites More sharing options...
muruku Posted September 22, 2010 Report Share Posted September 22, 2010 again, dun ask me to upload the entire bot to this forum pls ? considers doing this is actually infringes its product seller... i dun mind to post my thoughts & transcript where & how to improve the logic ... azam575 1 Quote Link to comment Share on other sites More sharing options...
shady2500 Posted September 22, 2010 Report Share Posted September 22, 2010 Dear fancy, take note the solid rock code I just scripted when inspiration came today.. The while (wild) loop force below clean up all open trades & pending orders when the MinProfit is hit.. happy coding... double Pips = TotalProfit(Magic); if (Pips >= MinProfit){ while(MyOrdersTotal(Magic) != 0){ CloseAllTrades(1, Magic); CloseAllTrades(2, Magic); DeletePendingOrders(Magic); } can you please share with all the new features? i also used to get this error from version 4 2010.09.22 15:38:25 Cannot open file 'C:\Program Files\FXDD Malta - MetaTrader 4\experts\indicators\ATR_Pips.ex4' on the GBPUSD,M15 i use 5digits. please help Thank you all Quote Link to comment Share on other sites More sharing options...
muruku Posted September 22, 2010 Report Share Posted September 22, 2010 ATR_Pips.ex4 can be found in www. we no need this indicator to attach to any chart... as the robot will able to read this indicator's reading via icustom statement. Hi, thank you for sharing but when i tried to test it, it showed me this message 2010.09.22 15:38:25 Cannot open file 'C:\Program Files\FXDD Malta - MetaTrader 4\experts\indicators\ATR_Pips.ex4' on the GBPUSD,M15 although i am using i on the one hour and also i am 5digits. i even tried to look for this indicator couldn't find it. can you please help me? Regards, Quote Link to comment Share on other sites More sharing options...
muruku Posted September 22, 2010 Report Share Posted September 22, 2010 243 pips for 3 days@24 hrs in operations. Running 1 instance full time, + another 1 one during NY to Asian session.. Even sleep also laugh. Quote Link to comment Share on other sites More sharing options...
shady2500 Posted September 22, 2010 Report Share Posted September 22, 2010 ATR_Pips.ex4 can be found in www. we no need this indicator to attach to any chart... as the robot will able to read this indicator's reading via icustom statement. Thank you very much for your replay but the link is not available or not complate :( Quote Link to comment Share on other sites More sharing options...
stijjn Posted September 22, 2010 Report Share Posted September 22, 2010 Thanks azam, When you say default settings atr in the ea : 7 right? Do I have to change the settings of the atr indicator too to :7? Quote Link to comment Share on other sites More sharing options...
gigamax Posted September 22, 2010 Report Share Posted September 22, 2010 Default setting in ATRPips is 14 ,7 is the modified setting proposed by muruku some threads ago. Quote Link to comment Share on other sites More sharing options...
muruku Posted September 22, 2010 Report Share Posted September 22, 2010 Zone C in actual rarely happens.. the theory behind slicing to each zone is ensure ATR_pips lines is FLATTEN & fall within any of these zones indicates market back to ranging phase again & where our bot come to the play... Look's like you able to cope up with this ATM machine ... what an amazing ! hi muruku, i`m still using the Zone A & zone B coding on my cent live account .... but maybe now i`ll try your new setting ..... :D Quote Link to comment Share on other sites More sharing options...
shady2500 Posted September 22, 2010 Report Share Posted September 22, 2010 Please help me to find the indicator atr_pips ... i am still getting this error 2010.09.22 15:09:53 2010.08.02 02:37 Cannot open file 'C:\Program Files\FXDD Malta - MetaTrader 4\experts\indicators\ATR_Pips.ex4' on the GBPUSD,M15 Quote Link to comment Share on other sites More sharing options...
muruku Posted September 22, 2010 Report Share Posted September 22, 2010 http://www.mediafire.com/?oab9q02liapm3l2 Please help me to find the indicator atr_pips ... i am still getting this error 2010.09.22 15:09:53 2010.08.02 02:37 Cannot open file 'C:\Program Files\FXDD Malta - MetaTrader 4\experts\indicators\ATR_Pips.ex4' on the GBPUSD,M15 shady2500 and didier 2 Quote Link to comment Share on other sites More sharing options...
gigamax Posted September 22, 2010 Report Share Posted September 22, 2010 too many fancy of C@bleR** here .. Here's the ATR pips logic i have... Global variables double ATRPeriod1 = 3.0; double ATRPeriod2 = 4.0; double ATRUpLimit1 = 13.0; double ATRDnLimit1 = 7.0; double ATRUpLimit2 = 21.0; double ATRDnLimit2 = 16.0; double ATRUpLimit3 = 26.0; double ATRDnLimit3 = 24.0; .. .. RefreshRates(); double ATRPips =iCustom(NULL,PERIOD_M15,"ATR_Pips",0,0); double ATRPrePips1 =iCustom(NULL,PERIOD_M15,"ATR_Pips",0,ATRPeriod1); double ATRPrePips2 =iCustom(NULL,PERIOD_M15,"ATR_Pips",0,ATRPeriod2); int MySignal = 0; if (ATRPrePips1 >= ATRDnLimit1 && ATRPrePips1 <= ATRUpLimit1 && ATRPrePips2 >= ATRDnLimit1 && ATRPrePips2 <= ATRUpLimit1 && ATRPips >= ATRDnLimit1 && ATRPips <= ATRUpLimit1 ) MySignal =1; if (ATRPrePips1 >= ATRDnLimit2 && ATRPrePips1 <= ATRUpLimit2 && ATRPrePips2 >= ATRDnLimit2 && ATRPrePips2 <= ATRUpLimit2 && ATRPips >= ATRDnLimit2 && ATRPips <= ATRUpLimit2 /*|| HowTight >= HowTightDnLimit && HowTight <= HowTightUpLimit*/) MySignal =1; if (ATRPrePips1 >= ATRDnLimit3 && ATRPrePips1 <= ATRUpLimit3 && ATRPrePips2 >= ATRDnLimit3 && ATRPrePips2 <= ATRUpLimit3 && ATRPips >= ATRDnLimit3 && ATRPips <= ATRUpLimit3 ) MySignal =1; MySignal = 1 ==> enter the trade ! Hi muruku, thanks again for your job and help. Sorry for this question but I need to be sure : the code above means your EA is using 2 ATRPips period settings (3 and 4) together (in the same time) ? And if the currency pair lays inside one of the 3 bands (ATRUpLimit1 = 3.0;ATRDnLimit1 = 7.0;ATRUpLimit2 = 21.0;ATRDnLimit2 = 16.0;ATRUpLimit3 =26.0;ATRDnLimit3 = 24.0), at least for one of the above ATRPips settings, it triggers(enter) the trade ? I plotted the two ATRPips but I've seen they never reached (in the last few months) the values of the first band (from 3 to 7) . Probably I didn't got your point ! Please explain. Quote Link to comment Share on other sites More sharing options...
gigamax Posted September 22, 2010 Report Share Posted September 22, 2010 Sorry...... I was wrong , the first band is reached too. The first question remain. Thanks Quote Link to comment Share on other sites More sharing options...
stijjn Posted September 22, 2010 Report Share Posted September 22, 2010 I've loaded it up :), will see how it goes. Thanks to everyone. Quote Link to comment Share on other sites More sharing options...
stijjn Posted September 22, 2010 Report Share Posted September 22, 2010 got an error; don't know what it means? 2010.09.22 15:36:09 CableLarikanMuruku_V4 GBPUSD,H1: #0 Error: 4105 Function: NewOrder(2,0.1,1.5666,0,0) 14 Quote Link to comment Share on other sites More sharing options...
stijjn Posted September 22, 2010 Report Share Posted September 22, 2010 Ok, sorry stupid me :) 2010.09.22 15:37:41 '286067': cannot login [Trade is disabled] Quote Link to comment Share on other sites More sharing options...
gigamax Posted September 22, 2010 Report Share Posted September 22, 2010 This is the latest setting from muruku.... i use this on my live account start from today :D http://www.multiupload.com/YYJMQK9FB2 give thanks to muruku for his great setting :D Circumstances that I am not a mql expert or coder...... it doesn't seems to me you code is using the muruku's zones. However thanks a lot for your contribution. Quote Link to comment Share on other sites More sharing options...
muruku Posted September 22, 2010 Report Share Posted September 22, 2010 These are the 3 ZONES/bands. When ATR_pips for current bar, (0) & previous 3 & 4 concurrently fall under either these ZONEs. The trade should trigger (MySignal = 1). R u crystal clear ?? double ATRUpLimit1 = 13.0; double ATRDnLimit1 = 7.0; double ATRUpLimit2 = 21.0; double ATRDnLimit2 = 16.0; double ATRUpLimit3 = 26.0; double ATRDnLimit3 = 24.0; Hi muruku, thanks again for your job and help. Sorry for this question but I need to be sure : the code above means your EA is using 2 ATRPips period settings (3 and 4) together (in the same time) ? And if the currency pair lays inside one of the 3 bands (ATRUpLimit1 = 3.0;ATRDnLimit1 = 7.0;ATRUpLimit2 = 21.0;ATRDnLimit2 = 16.0;ATRUpLimit3 =26.0;ATRDnLimit3 = 24.0), at least for one of the above ATRPips settings, it triggers(enter) the trade ? I plotted the two ATRPips but I've seen they never reached (in the last few months) the values of the first band (from 3 to 7) . Probably I didn't got your point ! Please explain. Quote Link to comment Share on other sites More sharing options...
gigamax Posted September 22, 2010 Report Share Posted September 22, 2010 Everything is clear !!!!! Thanks for your help. Another stupid question : wouldn't be easier (at least for me) to run 3 (one for each zone) EAs with different magic in the same MT4 platform ? Please don't shoot me ! Quote Link to comment Share on other sites More sharing options...
shady2500 Posted September 22, 2010 Report Share Posted September 22, 2010 Thank you Muruku... i have got this error 2010.09.22 17:02:21 '2006005': order sell limit 0.10 GBPUSD opening at 1.56702 sl: 0.00000 tp: 0.00000 failed [invalid S/L or T/P] 2010.09.22 16:46:35 '2006005': order sell limit 0.10 GBPUSD opening at 1.56805 sl: 0.00000 tp: 0.00000 failed [invalid S/L or T/P] what can i do to solve it ? and can you please if you have the newest version with 5digits broker can you share ? Thank you Quote Link to comment Share on other sites More sharing options...
muruku Posted September 22, 2010 Report Share Posted September 22, 2010 dun be greedy. If i were you, i will turn on max 2 instances during NY-Asian session with 0.1 lots.. The rest of 24 hrs run, 1 instance only to protect the $ i would suggest maintain the same codes for all the instances except each will run with diff magic (change this number everytime before you enter the trade, who knows your broker is nasty one).. also keep your eye open for kind of bugs found like .. - if Instance A & B open trades almost same time, when their respective MinProfit hit, are ALL of them close up happily with at least greater & equal to MinProfit.. ?, you may want to insert the ordercomment so that visible which to which instances are managing its trades. - Will Instance A interfere B in its opened trades ? - We shouldn't expect duplicate entries of buy/sell limit by each instance .. you need to fix its logic to ensure this is not happened.. i 'm still studying if there's a logic to "watchdog" if duplication of pending orders happened, how to delete either one. WOW.. too many wording for today. Cheers ! Hopefully your guys enjoy them ! Quote Link to comment Share on other sites More sharing options...
stijjn Posted September 22, 2010 Report Share Posted September 22, 2010 what means error 130 function Quote Link to comment Share on other sites More sharing options...
RVB Posted September 22, 2010 Report Share Posted September 22, 2010 Which is the current version (with mods) that is being used for these discussions? Quote Link to comment Share on other sites More sharing options...
isssac Posted September 22, 2010 Report Share Posted September 22, 2010 Is it normal for the backtest to stop working after the first order is deleted? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.