| New signals service! | |
|
|||||||
| Register in Forex TSD! | |
|
Trading Systems Leaders in this forum (automated trading systems) are winning more than 3000 pips in a month (30000$ investing one lot every time). Click here to register and get more information |
|
![]() |
|
|
LinkBack (1) | Thread Tools | Display Modes |
|
|||
|
Is it possible , two EA in the same time?
Hi evrerybody
Is it possible to make working my two EA? - in the same time - in the same Timeframe (ex : 1 minute) - and with the same Currency Pair (ex :EUR/USD) I've change the MagicNumber (EA_1 = 10 ; EA_2 = 20) but they're working one after another even if, the conditons for a trade are good for each . Help me please. Thanks! |
|
|||
|
Quote:
Hello, Thanks again for your time. Just for your info, I resolved the issue. Your suggested modification was the first step in the right direction. It needed on additional modification (in bold type) as follows: if (Buy_Signal && BuyOrders < Max_Buys && BuyOrders==0) Order = SIGNAL_BUY; if (Sell_Signal && SellOrders < Max_Sells && SellOrders==0) Order = SIGNAL_SELL; Thanks again. Perhaps, if you don't mind you could help me with one other question. I would like to add the EA to have the flexibility to close any open order after X number of days, where X is adjustable in the expert setup dialog. So, say a buy trade opens on a certain date and time, be able to close the trade three days later at the same time of day? Any ideas or suggestions is appreciated. |
|
|||
|
Indicator with this code:
Hi my Dears,
I want 2 indicators in MT4 with these code below: (with arrow signal buy/sell on the chart) Number 1: ---------- MA1 = SMA(5,Close), MA2 = SMA(10,Close), MACD(12,26,9) To signal a long trade: MA1 > MA2, RSI(14) > 50, and MACD Fast > MACD Signal To signal a short trade: MA1 < MA2, RSI(14) < 50, and MACD Fast < MACD Signal. ---------- Number 2: ---------- F1 is Fractal Up Level and F2 is Fractal Down Level in the code below UpTrend and DownTrend(Description): F1:=ValueWhen(1,H<Ref(H,-2) AND Ref(H,-1)<Ref(H,-2) AND Ref(H,-3)<Ref(H,-2) AND Ref(H,-4)<Ref(H,-2),Ref(H,-2)); F2:=ValueWhen(1,L>Ref(L,-2) AND Ref(L,-1)>Ref(L,-2) AND Ref(L,-3)>Ref(L,-2) AND Ref(L,-4)>Ref(L,-2),Ref(L,-2)); a:=Cross(H,F1); b:=Cross(F2,L); state:=BarsSince(a)<BarsSince(b); {Signal Long and Short} LongSignal:= state<Ref(state,-1); ShortSignal:=state>Ref(state,-1); {Trend Up and Down} UpTrend:=state>0; DownTrend:=state<1; --------------------------------------- Thanks and Best Regards, Khamoosh |
|
|||
|
You need what kind of help ? Indicators.." You can get some here..what you need now is to learn and practice,,he..he...he..
|
|
||||
|
Quote:
int IndicatorCounted( ) The function returns the amount of bars not changed after the indicator had been launched last. The most calculated bars do not need any recalculation. In most cases, same count of index values do not need for recalculation. The function is used to optimize calculating. Note: The latest bar is not considered to be calculated and, in the most cases, it is necessary to recalculate only this bar. However, there occur some boundary cases where custom indicator is called from the expert at the first tick of the new bar. It is possible that the last tick of the previous bar had not been processed (because the last-but-one tick was being processed when this last tick came), the custom indicator was not called and it was not calculated because of this. To avoid indicator calculation errors in such situations, the IndicatorCounted() function returns the count of bars minus one. Sample: int start() { int limit; int counted_bars=IndicatorCounted(); //---- check for possible errors if(counted_bars<0) return(-1); //---- the last counted bar will be recounted if(counted_bars>0) counted_bars--; limit=Bars-counted_bars; //---- main loop for(int i=0; i<limit; i++) { //---- ma_shift set to 0 because SetIndexShift called abowe ExtBlueBuffer[i]=iMA(NULL,0,JawsPeriod,0,MODE_SMMA,PRICE_MEDIAN,i) ; ExtRedBuffer[i]=iMA(NULL,0,TeethPeriod,0,MODE_SMMA,PRICE_MEDIAN,i ); ExtLimeBuffer[i]=iMA(NULL,0,LipsPeriod,0,MODE_SMMA,PRICE_MEDIAN,i) ; } //---- done return(0); } |
|
|||
|
Quote:
PHP Code:
PHP Code:
|
![]() |
| Bookmarks |
| Tags |
| candle time, CHinGsMAroonCLK, coders guru, expert advisor, forex, how to code, I_XO_A_H, mechanical trading, trading |
| Thread Tools | |
| Display Modes | |
|
|
LinkBacks (?)
LinkBack to this Thread: http://www.forex-tsd.com/metatrader-programming/554-how-code.html
|
||||
| Posted By | For | Type | Date | |
| Need an experienced programmer? - Page 2 | Post #0 | Refback | 09-24-2008 07:24 AM | |
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to code this? | iscuba11 | Metatrader 4 mql 4 - Development course | 1 | 08-03-2007 05:22 PM |