Welcome to Forex-TSD!, one of the largest Forex forums worldwide, where you will be able to find the most complete and reliable Forex information imaginable.
From the list below, select the forum that you want to visit and register to post, as many times you want. It’s absolutely free. Click here for registering on Forex-TSD.
Exclusive Forum
The Exclusive Forum is the only paid section. Once you subscribe, you will get free access to real cutting-edge Trading Systems (automated and not), Indicators, Signals, Articles, etc., that will help and guide you, in ways that you could only imagine, with your Forex trading.
Elite Section
Get access to private discussions, specialized support, indicators and trading systems reported every week.
Advanced Elite Section
For professional traders, trading system developers and any other member who may need to use and/or convert, the most cutting-edge exclusive indicators and trading systems for MT4 and MT5.
Gidday I am slowly fixing the errors in some if my ea's ( and learning alot on the way) but what does this mean.
2007.10.24 21:22:24 1998.11.20 06:00 The Abyss GBPJPY,Daily: invalid double number as parameter 6 for OrderSend function
I can't find anything on that error what should I be looking at.
Hi
Is it possible to recover a data type from an indicator (3 MA Cross w alert) to put it in a EA?
This is what I want to do :
In the indicator (3 MA Cross w alert) I put a data type : double execute_trade = "ok_buy" or execute_trade = "ok_sell" here :
Hi
Is it possible to recover a data type from an indicator (3 MA Cross w alert) to put it in a EA?
This is what I want to do :
In the indicator (3 MA Cross w alert) I put a data type : double execute_trade = "ok_buy" or execute_trade = "ok_sell" here :
and I'd like to recover "excute_trade" in my EA like this :
***********EA***************
if (excute_trade== "ok_buy")
Order = SIGNAL_BUY;
if (excute_trade== "ok_sell")
Order = SIGNAL_SELL;
****************************
But I don't know how to do
help please
Best regards
You must use iCustom function to retrieve the value of the buffers (ie the arrows);
Quote:
double iCustom( string symbol, int timeframe, string name, ..., int mode, int shift)
Calculates the specified custom indicator and returns its value. The custom indicator must be compiled (*.EX4 file) and be in the terminal_directory\experts\indicators directory.
Parameters:
symbol - Symbol the data of which should be used to calculate indicator. NULL means current symbol.
timeframe - Timeframe. It can be any of Timeframe enumeration values. 0 means the current chart timeframe.
name - Custom indicator compiled program name.
... - Parameters set (if necessary). The passed parameters and their order must correspond with the desclaration order and the type of extern variables of the custom indicator.
mode - Line index. Can be from 0 to 7 and must correspond with the index used by one of SetIndexBuffer functions.
shift - Index of the value taken from the indicator buffer (shift relative to the current bar the given amount of periods ago).
The parameteres p1 to p10 are the values to send to the indicator as the extern parametres. For example, p1 means the value to be assigned to FasterMA, p2 to FasterShift, and so on up to the last extern declaration p10 SoundAlert. See the indicator's code to know the order and the signification of them.
Gidday I am slowly fixing the errors in some if my ea's ( and learning alot on the way) but what does this mean.
2007.10.24 21:22:24 1998.11.20 06:00 The Abyss GBPJPY,Daily: invalid double number as parameter 6 for OrderSend function
I can't find anything on that error what should I be looking at.
int OrderSend( string symbol, int cmd, double volume, double price, int slippage, double stoploss, double takeprofit, string comment=NULL, int magic=0, datetime expiration=0, color arrow_color=CLR_NONE)
As you can see parameter six is the stoploss. Make sure your stoploss is defined as an int. Next, make sure in your OrderSend() command that you are multiplying the stoploss by point. This converts to the right double for the currency you are trading.
Example for long:
ticketa=OrderSend(Symbol(),OP_BUY,lotsize,Ask,slip ,Ask-intStopLoss*Point,Ask+intTakeProfit*Point,"Comment ",magic,0,Green);
Example for short:
ticketb=OrderSend(Symbol(),OP_SELL,lotsize,Bid,sli p,Bid+intStopLoss*Point,Bid-intTakeProfit*Point,"Comment",magic,0,Blue);
That helped alot but has open a new problem lol it now buys but no sell well not in the right place. I have been trying to buy what all three indi are blue and sell when all red.
I think I have picked the right name "The Abyss" for the ea. as that is where I am sitting trying to code my way out. LOL
2007.11.24 10:14:44 2007.11.23 12:00 The Abyss EURUSD,H4: Error opening SELL order : 0
I'm building a system I think it is very good, I tested the idea before for 3 months, Now I'm trying to coding an indicator which will be asap in the forum so we can test it and it will really will make good money i think:
Plz help me for now to convert these lines into mql4 coding:
1- I have vairable X , this will have a value and I'm calculating it now
SO We have X as an Integer
2- the indicator must check the currnet GMT Time, It must be 6:00am GMT - Time Frame 1 H
-- check GMT TIME 6:00am, WHEN this candle close, we need to calculate the following Variable Of this candle:
High - Low = A
A / 2 = B
B - High = C = SL
D = X * 30%
Buy_Entry= D + C
Buy_Target= C + (X * 60%)
Sell_Entry= C - D
Sell _Target= C - (X * 60%)
Then:
I want to drow the result as lines on the chart with GreaN Area for buy and red Area for Short According to Entry for Buy and Sell and SL
these must be automaticly apear as soon as GMT 6:00 candle finished , Time Frame 1H, so caluculation must be according to 6:00 to 6:59am GMT Candle high and low
PLZ Convert this to MQL4, so i can test it and get back again to puplish the result
That helped alot but has open a new problem lol it now buys but no sell well not in the right place. I have been trying to buy what all three indi are blue and sell when all red.
I think I have picked the right name "The Abyss" for the ea. as that is where I am sitting trying to code my way out. LOL
Beno, I'm not sure about this one. I have usually not had good experience with using color changing indicators in EA's. Open your data window with your indicators attached and find out what numerical value is returned for each color. That may help your coding, also make sure you are calling the correct indicator buffer at the right time. (I'm sure you have already done that) You may have better luck with help if you post the entire EA, if you really need help. Also, personally I would code it with 2 separate Ordersend() functions, one dedicated to shorts, and one dedicated to longs. That's just my opinion, it makes things easier to follow.
Good luck, we all have had our own versions of "the Abyss"!