MQL4 and MetaTrader 4 - page 321

Hello everyone, I am having a hard time writing the perfect code for what I want. Basically I have the following scenario: Candle 1: 12:00:00: Indicator value=5 12:03:24: Indicator value=5.2 12:04:59: Indicator value=5.5 Candle 2: 12:05:00: Indicator value=6 12:09:59: Indicator value=8 Candle 3
Hello guys!!! I found an indicator here on the fórum that return several errors when I try to compile it and I have no clue how to fix those errors. On the same page, seems that was the file compiled already, but this one seems to have errors on the alert generation. The arrows itself change when I
Hi Folks, So I'm setting arrays, in particular I want to remember which pairs and profit for that pair per individual trade, which appear to be a problem already. I can't seem to have a String and Double Array, so Pairs[string 1][ double 1][double 1]; or Pairs[1][1][1] appears to be not possible? I
Hi, I downloaded the Dukascopy 1D data (Bid and Ask) form the JForex platform and I am trying to import it into MT4. I want to backtest using this data and I don't know if I should download the 1M data and then transform it to all timeframes? My strategy is only for the daily chart and I will
hey guys, I want to use f12 in backtesting and learn price action at the same time. Is there a way to switch between mtf without the chart skipping into the future? Or what would be the best way backtesting with mtf? Thanks
Hi, I have an issue with MT4... I opened a SELL position on GBPUSD with SL and TP and MT4 closed the position 8 pips above TP. As a result, the trade ended as a loss. I have attached the trade history and the journal. Trade number is 44846559, GBPUSD SELL with SL 1.24826 and TP 1.23287 The trade was
[Deleted]
Hi, First of all, sorry for my bad English, bot does anyone could help me here please ?! :) I would like to know how to use my EA on my own VPS H24 ? Is it possible or not ? How ? I want to be able to drive my own EA on my own VPS H24, but how? I will have to connect my EA to a lot of trading
Hi... I need to limit number of opened orders in an asset AND limit one order per candle too. See my code... it's allowing more than one orders per candle. I fixed it to allow 2 orders, but only one per candle: input bool LimitBar=true; // Limitar 1 ordem por vela?input int MaxOrders = 2;int...
This indicator is working except for that it will not update on each new bar. I have to reload the indicator for it to update. I know the solution is somewhere in the Start function, and because i am not a programmer I have failed to try and fix it. Could someone tell me what section of the code to...
Hi everyone, I'm a newbie who recently started learning MQL4. I've been struggling with the problem below for quite a while now without success. Basically what I'd like to achieve is having the OBV indicator with a moving average in a separate indicator window. I used the OBV.mq4 for a start and
HI, please give me some advice. Below is the code sample to select the 2nd oldest opened order. I want to do similar things. I want to put ticket number and order profit in 2-dimentinal array. For example, [Ticket# , Profit] #12, $12, #14, -$1, ....... I see that I can use for next roop code to
Hello I am backtesting an EA and a strange problem is happening to me. When I set it with autolots for 0.01 lot for each 500 balance, with 10,000 starting balance, it works perfectly backtesting in "Open Prices Only " mode, no 131 error or any kind of issues. Now, with exactly same settings, but
I am trying to understand the logic behind the half-trend indicator so I can port it to python. But since I don't know much about MQL4 , it's a bit difficult to understand how this indicator works. Can somebody explain it to me please ? Thanks
[Deleted]
Hello there My EA requires counting the bars after an order has opened (measure MACD values against a 'sloping' (changing) value (not the signal)). This is what i thought (my problem): get the Order Open Time - OOT - (in seconds),datetime OOT=OrderOpenTime(); get the current time - Bar 0,    int...
Recently upon starting the terminal, not all of the indicators are loaded. Also, every icon has a gray diamond symbol which indicates the MQL4 file is not present. Upon checking the indicator folder, all MQL4 and EX4 files are present. After trying a bunch of things including a new install of
Hello, I want to compare the Bid and the Candle open price at the beginning of each candle, in EA. If Bid goes 20 Point(or more) higher than the Candle open price, Take a position. If Bid goes 20 Point(or more) lower than the Candle open price, Take a position. and And then wait for the next candle
hox i can put extension and indacatorsby ig market on mt4
My MFI expert advisor. If the position is in the overbought or sell zone after closing, it opens a new position immediately. Idont want this. I want it to open when the MFI indicator exits the overbought or oversold region and re-enters. What command should be added? Help please
I couldn't get in touch with the author , therefore I decided to ask in the forum to help me understand some function : Thank you in advance, please bare in mind that I am not professional IT or trader. so I am just an amateur, but I like to study more in Mql4 and EA, so please help me understand
  High sllipage  (2)
hello guys. I have a question. I wan put my system like a provide signal, but when i check a sllipge is so bad for other trading server. Dont know why.? Do you think it help me when i rent VPS from mql5? Do you have some experiences. Thanks for advise
i have been looking at tutorials and basic stuff just trying to figure out how to close a order i created this program which should both open and close a buy position each tick input double l=1; void OnTick(void) { int p = OrderSend(Symbol(),OP_BUY,l,Ask,3,0,0,"buy",1,0,Green); bool
My demo trading account set up thru MT4 only shows limited symbols in Forex and 2 in metals. How do I add more ie the FTSE 100 and North American stocks and index's
Hi, I want my EA to have a custom button on screen. When I press this button it should allow me to place a horizontal line on the chart. However, whenever I click on my button, the Hline(s) is/are also immediately placed. It seems the CHAREVENT_CLICK gets triggered anyways. Anyone can help me fix...
Hi friends, When I read an indicator value in a time frame other than the chart current time frame I get wrong values! Is there any consideration to follow to avoid this problem? Thanks, Shahram
Indicator only alert pop-up windows Help me repair him alert to terminal android smartphone Thank so much
Greetings. This indicator is called Pivot Preference. It plots (1-(P-S1)/(R1-P)) in a separate window, where P is the central Pivot (HLC/3), S1 is first support((2*P)-PreviousHigh), and R1 is first resistance((2*P)-PreviousLow). This indicator (#PivPrefBias.mq4) has #property
Hello, Trading is hard. Why trade? To make money. How to trade? Buy low, sell high. This is essentially the gist of it, right? To decide whether I want to Buy or Sell I first need a Bias. I figured I'd take the Open Price as my starting point and set a target on previous highs if my bias is Bullish
Hi, At times, when I try to close multiple orders, I am ending up with "prohibited by FIFO" error. I would like to know is there a simple way to sort the orders by OrderOpenTime and NOT the ticket number? Added the code logic in the comment
Hey guys, Having an issue with getting data from WebRequest's JSON response. I know, I know, this is probably a common issue, but I can't figure it out. This is the results array response from WebRequest
I'm just learning to code. I'm learning with a course I found on Udemy. So far it's a great course. I've been following along using the code I learn and making sure that I'm writing properly. Well, I just learned how to send an order for the first time. Below is the code I'm trying. I've copied the