Here is the code
|
|||
|
Thanks Bossxero for your interest.
What I want it is a stop when the trade goes against me, i.e. when the conditions become the conditions opposite of the opening of the trade. Best, if it's not too much workis would be a stop and reverse. Thanks again. Jo |
![]() |
|
|||
|
Quote:
Hi Scorpion, I have use the EAbuilder and I find it very usefull indead but I have these 2 problems: FIRSTly SETUPS: If current bar is higher than previous bar then buy.. PROBLEM: The order will not be executed until the current bar is closed. This makes my strategy redundant.(It must execute the trade immediately the condiotion is fulfilled). Secondly I'll use an example in this one.(MACD CROSSING) SETUPS: Buy when MACD is above signal line and I set my take profit to 30pips. PROBLEM: The order is executed promptly(after the close of the current bar) and when I hit my 30 pips profit, a new position is opened which is not what I want. I hope u understand me scorpion Please help me on this coz I really like this EA builder but I am really stuck here!!! ![]() Karama |
Order Reliable
|
|||
|
Scorp - have you ever used the Order Reliable routines? Do you think the extra logic is worth it? I've missed some trades on IBFX with 146 trade context busy. Do you program for this, like put your trade in a loop while this condition is true?
|
|
||||
|
Most standard EAs will retry because it evaluates the order logics on every new tick, as MetaTrader executes the Start() method every tick.
The Sleep(10000) simply tells MetaTrader to pause executing the Start() method for 10 seconds. If ordering-related procedure is execute again within 5 seconds, MetaTrader will throw "too frequent" and "trade context busy" error. |
|
|||
|
Makes sense - I needed to change the reverse logic which said: if there's a signal and a position then delete the position and take a new one the opposite way - I pulled the delete and thake position apart, so it deletes the first time, but keeps trying to take the new position on every tick while the signal is hot, like you described. This is better logic - should have thought of that possibility myself. Thanks - Bill
|
![]() |
«
Previous Thread
|
Next Thread
»
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| ZeroCode Sample: Create "10-Minute" Strategy Expert | scorpion | Tutorials, Tips & Tricks | 16 | 04-14-2008 12:29 AM |
| ZeroCode Expert Running 3 Majors (?) | Scicronys | MetaTrader and ZeroCode | 8 | 12-12-2007 09:58 AM |
| Support and Resistance Expert Advisor | suffic369 | Classified Ads | 2 | 07-03-2006 07:57 AM |
| Calling out an expert | gazuz | MetaTrader and ZeroCode | 1 | 10-21-2005 08:48 AM |
| Can not get the Expert to work...Help! | jimbo61 | MetaTrader and ZeroCode | 2 | 08-19-2005 04:57 AM |
All times are GMT. The time now is 06:38 AM.
Powered by vBulletin Version 3.6.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.1.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.1.0
Registered members have access to special online forex currency trading tools, software, mt4 expert advisors and indicators. Register now












Linear Mode

