MQL4 and MetaTrader 4 - page 7

To post a new topic, please log in or register
Hello, As you can see in the video, when timeframe M1 is selected, the monday 16th of september 2019 disepear and the yellow ellipse is not on candles. Janfi
  Ordermodify error 130 (15   1 2)
Hi, I have created an EA, that works well for me, but I tried to change it a little bit, but can not manage to make it work. All I want it to do is to open an order with a trailing stop. The problem is, the trailing stop is different for each trade (it depends on the high of the current candle). It...
Hi! Inspired by Bill Williams and what he calls "Point Zero", I have been several days thinking about a way to detect potential tops and bottoms using Fractals, Momentum, Moving averages and Market Facilitation Index. I thought it wasn't really possible and tops and bottoms were random, but I think...
  Currency heat map (157   1 2 3 4 5 ... 15 16)
CP6 directed me to a site with something like this on their web page, and asked if it can be made as indicator. Well, here it is (changed their approach ) PS : if you, by chance, get a display like on the lower displayed indicator, download and install the MS LineDraw font in the attachment and...
l have tried many code , but still can't find way to get today date. Example Today = 10-Sep-2017 When l doing backtest on = 1-Jan-2015 How to get today date? Thank you. Best regards.
I want to use classes inherited from CChartObject (Metaquotes standard library). For example, I want my script to draw a trend line by using CChartObjectTrend class. But the parent class (CChartObject) destructor contains deleting the object. That means when the script is ended the trend line is
Hi friends, Today I was going to update my code and when I used the styler feature in MQL4, I suddenly understood that with the new update, using the styler feature causes some undesirable changes with the ELSE IF structure. I want to have the previous structure of the ELSE IF not the new one. I
hi guys hope doing well this ea is not working. it doesnt have any problem but i dont know why it's not working can anyone fix it please? thank you
Hello. Can someone please advise me what would be the shortcut key for Pause/Break Pause strategy tester? I use visual mode for testing and I have EA to pause when ever I it trades, And find it very troublesome to click everytime I need to restart. I have been searching for more than 3 days but...
void rolLongStopA() { for(int b=OrdersTotal()-1; b>=0; b--) { bool LongA; if(OrderSelect(b,SELECT_BY_POS,MODE_TRADES)) if(OrderMagicNumber()==Magic) if(OrderType()==OP_BUY)
Hi all, I'm searching for a good median renko expert for MT4. Could you suggest a good version? Thank you
I'm getting an error, can't divide by 0 when i try to run my EA on AUDCAD. I'm pretty sure i've narrowed it down to: MarketInfo(Symbol(), MODE_TICKSIZE). If i print that. It returns 1e-5 double LotSize = MarketInfo(Symbol(), MODE_LOTSTEP); double riskAmount = AccountFreeMargin() * (Risk / 100);
Hello, I want to get the chart data for, for example H1, M15 and M1 so that I can display something about them regardless of what time period is currently being displayed. (I am very new to MT4, but not programming) *blushes* I have seen an example where within OnCalculate, the flowing code is used
Hi guys, anyone have ideas about how to delete only visible objects on current timeframe? I have this code here for delete all objects: if (ctrl_pressed == false && lparam == 16) // Shift key pressed ctrl_pressed = true; else if (ctrl_pressed == true) { if (lparam == 68) {
Hi! I'm looking for an indicator that paints a higher timeframe HA-candle in the background of a lower timeframe chart. In the link from for example on a M5 chart there is the H1 HA
Problem description: Chart cannot shown in full screen. Chart is blocked by quotes bar
I have script to change chart window title calling winapi sendmessage (WM_SETTEXT command):   If I select other chart, my custom title is changing to previous name. How to set window chart title to be valid even if window lost focus?  
  Limiting one entry per pair (21   1 2 3)
Hi: I have been attempting to limit only one transaction (either long or short) per pair with the following code but it constantly opens up two transactions of each pair. Could it be due to asynchronous messages between the terminal and server? I tries sleep(3000) but that did not work either so I...
Hiya, I have noticed that the EA I am copying has executed a trade today that my MT4 has not copied. Do I have to be logged in to the account at all times for the copying to work correctly as I was logged in to another of my accounts most of the day. If this is so, is there a way I can be logged
Hello to All Please let me know how to solve this problem While the system is testing the EA during the Automatic validation this error appear : ERR_NOT_ENOUGH_MONEY: The only thing I can change is the spread before the test. For my EA - all the parameters are manageable / changeable - depends on
Hi This has probably got the better of me for a good 2 days now. In the attached code when I run it in Tester I should only be able to get "Short B called" to print in the Journals tab when the bool for it (rolShortB) is set to True. But, I can't see where it is getting switched to True?! Please can
  Currency Index Formula (11   1 2)
Hello , I found in google USD Index formula : usdx = usdeur ^ 0.576 x usdjpy ^ 0.136 x usdgby ^ 0.119 x usdcad ^ 0.091 x usdsek ^ 0.042 x usdchf ^ 0.036 x 50.14348112 But the same for EUR Index ,GBP Index ,CAD Index ,JPY Index ,CHF Index ,AUD Index , NZD Index cantbe find  I just want their...
Hello, I have programming background but I am new to EA development. I have developed an EA. It is working fine and generating signals during back testing. But when I am attaching the EA to a Real time Chart, the EA is not getting activated, though I am candles are formed from the real-time ticks. I
  Trade box (2)
When I click on view then click on terminal the trade box does not show, what can I do to correct this, have already reinstalled metatrader 4
Hi, I need help with this I'm trying to calculate the price of the previous candle in order to set the Stop Loss and Take Profit for a Order Send. The problem is I can make the decimals into a number of pips. If someone could help me with this, I will appreciate that //---- Valores de
Hi, I'm trying to create an expert advisor that creates and object (Arrow up or down) depending of an if. The signal works, they show me the alert but the program doesn't create the arrow. If someone can help you I will appreciate. This is part of the code I'm doing if( diff_2 <=
Hi all, I'm using the attached indicator in this way iCustom(Symbol(),PERIOD_H4,"D",1,0) // for the upper bandiCustom(Symbol(),PERIOD_H4,"D",0,0) // for the middle bandiCustom(Symbol(),PERIOD_H4,"D",2,0) // for the lower band The values I obtain are correct (with default parameters value), but I'm
I have a file called test.mq4. I need to get its content as a string in my other mq4 program. The test.mq4 is an UTF-16 file. If I convert it to UTF-8 (by an external text editor), I can get its content like this: uchar filedata[]; int handle=FileOpen("test.mq4",FILE_READ|FILE_BIN);
Good afternoon How do I upload a file (pic.jpg) from a MT4 folder to a remote server? I'd like to know also if there are some libraries to import and which functions can I use? Thank you
Hello, The new build of MT4 has come with its bugs! Open any MT4 and log in. Hit Ctrl+T and then the Signals tab down. You scroll on the Signals but may not see what you are looking for. In this case you are supposed to search from the top-right corner. The search results appear on a search tab