MQL4 and MetaTrader 4 - page 113

  Else If  (2)
if ( (LongFilter== true &&TimeFrame==Weekly&&( iHigh ( 0 , PERIOD_W1 , 0 )- iLow ( 0 , PERIOD_W1 , 0 ))>Range*point&&Bid<WPL&& YL== 1 && iLow ( 0 , PERIOD_W1 , 0 )< iLow ( 0 , PERIOD_W1 , 1 ))|| (LongFilter== true &&TimeFrame==Daily&&( iHigh ( 0 , PERIOD_D1 , 0 )- iLow ( 0 , PERIOD_D1 , 0
Morning, So I'm plotting a horizontal line on my chart, except I'm not. My code is the following: double sma = iMA ( NULL , 0 ,10, 0 , MODE_SMA , PRICE_OPEN , 0 ); ObjectCreate ( 0 , "Horiz_Line" , OBJ_HLINE , 0 , 0 ,sma); ObjectSetInteger ( 0 , "Horiz_Line" , OBJPROP_WIDTH , 3 );
Good day, I'm still learning MT4 and I have this quick question. Once I dragged the EA to the chart and clicked the auto trading button on the tools bar, will the EA trade on all symbols or it only will trade on the symbol of the current chart? if so how to trade on all other symbols? Regards
I've been trying to make a trailing stop EA for a while, and this is the first time I've nail it, sort of. when I do the back test I get the error 4108 (Invalid Ticket), when the EA tries to modify an order. I think it shouldn't happen since I use the OrderTicket() function to get it, has anyone any
Hi Gentlemen and Ladies, Is there an existing indicator that shows previous day high and low that plots with a text as per photo? I have the indicator but i dont have that text at the end of each line, is it possible to edit the indicator and have that text added at the end of the line? anyone with
Does anyone know how I can edit the notification messages that are sent from mt4 to phone. The notifications are too long for me and I want to shorten them
[Deleted]
I'm currently looking for a good Mt4 broker for scalping since my previous broker's trading conditions were not getting any better. A broker with tight spreads and a commission cost of $8 would be fine. Any suggestions
Hi all I want to run my EA on all pairs but to open on one pair only. So for an example, EA is currently running on EUR/USD,GBP/USD,XAU/USD etc. The EA decides to open a trade/s on EUR/USD, my EA will open trade/s on other pairs. Please help on how I can prevent this from happening. #property strict
  Close Old Orders  (3)
Hi All - I need help with the following scenario: Example I am creating an EA based on the EMA cross over/order. So when an EMA cross under I would do a sell and when it cross over I would do a buy. I am trying to close any previous position (buy/sell) when the EMA goes opposite to the order. If
#property strict #property indicator_separate_window #property indicator_buffers 17 //#property indicator_color1 DarkGreen // Color of the 1st line //#property indicator_color2 Navy // Color of the 2nd line //#property indicator_color3 Yellow // Color of the 1st line //#property
Full code in attachments. i can't understand why i can't properly move all active orders SL's to BreakevenPrice() Function simply not looping thru all SL's and return "Error 1" which means i try change SL with same SL, but BreakevenBuy() already moved father (ELI5 On attached image : I want to move
hello i have developed an EA that use to work well. but since almost a week ago when it wants to close orders, it gives me invalid Ticket and invalid Price error. the strange part is that right after the OrderClose a put an Alert to see if the Ticket or the Price is Wrong. but it is right. Alert
I take the original MQ RSI and add various levels, but the levels are above the RSI and it's ugly. How do I get them behind the RSI ? //+------------------------------------------------------------------+ //| RSI.mq4 | //|
Hello, I was wondering if is there anyway to acquire the date of the events from this function: void PrintCalendar() { MqlCalendarEvent events[]; //--- get EU currency events int count = CalendarEventByCurrency ( "EUR" ,events); Print ( "count = " , count); //--- 10 events are
Hello, Did anyone managed to connect MetaTrader4 to ***? What bridge did you use? Also I would like to use MetaTrader4 EA but*** is logging off overnight automatically. Is there any way to prevent this? Thank you in advance
I would like to be able to take the function below which saves a screenshot to a file and attach a listening function that saves a screenshot every 5 minutes or so. What would be the best way to go about this in mql? int start(){ if(!WindowScreenShot(StringConcatenate(Symbol(),"_",Period(),"_"...
It looks like a call to MessageBox() breaks something in the ability of MetaTrader to detect key presses correctly. Consider for example this sample EA code: void OnChartEvent ( const int id, const long &lparam, const double &dparam, const string
Hello developers of MT5! I use the newest (actual) version of Windows 10, 64 bit. After installation with error, is no possible open MT4/MT5 (of course). I have installed more versions of C++ in PC. It is source of problems? Can you me please help? Can you repair errors in next resale please? (In...
How can I compare and close first and last order when they in profit? Meaning when EA opens 5 buy orders, compare 1st and 5th orders, close when they are in profit, likewise compare 4th and 2nd order, close when they are profit. Instead of closing all together, how can i close in this way? Can you
I need help adding 2 moving average filter to the buy and sell entries of this EA. The EA will place a buy order when the fast MA is above the slow MA and a sell order when the fast MA is below the slow MA. The source code is attached below
  MT4/Ubuntu/WINE/Soft4FX  (12   1 2)
I'm pretty new to all of these things (been running Ubuntu for only a few months) I've recently installed MT4 on Ubuntu using the most recent version of WINE. Seems to be running okay.  Today, I just started trying to use Soft4FX (a backtesting EA plug in for MT4) with it and whenever it starts up,...
  MT4 Stats Wiped  (2)
Hi, Following the recent MT4 update, all my historical statistics have been wiped and all I see is the past 1 week statistics. Are you able to restore all the historical stats? My MT5 stats are still intact and work fine. Regards, Carlo
Hello together I tried to search through google for my problem but didnt find any solution. Im running a bot on a demo account and receicve the error message cannot order spread is too high. Max spread is 50 pipettes and the actual spread when received the error was never higher than 50 pipettes i
Please Help. Please Guide. I am running windows 10. I am posting here because I am stuck Running MT4 on 43 inch 4K Monitor and need Help as I can't return this Monitor. I do not face this issue on 32 inch Full HD Monitor anytime. I bought a 43 inch 4K Monitor. But the Candles appear VERY THIN with...
I have an EA to ride trends on Nasdaq. Let's say that EA opens 6 trades. Trades will be closed by the EA all at the same time. My question is: Once the 6 trades are closed, can the EA be coded to know if one of that trade reached for example 500 pips profit? Because once 500 pips are reached, the EA
  news filter  (1)
Please, I want to add a news filter for the attached trader Greetings and appreciation to you all
There is no CurTime() function on https://docs.mql4.com/function_indices aaand I spent 1 hour looking for what was wrong with my CurTime(var something) function :( it's obsolete https://docs.mql4.com/obsolete but still override custom function MT4 Version: 4.00 build 1355 16 Mar 2022
Hi everyone I have been reading the topics on this forum for years and I love the great feedback here. I open my first topic, to share and ask for your opinion. I am trying to make an indicator that automatically gives the fibonacci time of the current candle (not future candles), I insist it is the
[Deleted]
  Take profit MQL 4  (12   1 2)
Hi, If i want to modify a take profit, I've tried this but it doesn't work. res=OrderModify(OrderTicket(), OrderOpenPrice(), OrderStopLoss(), TP-OrderOpenPrice(), 0 , CLR_NONE); //where a Value is - from the open price
[Deleted]
Hi, i wanted to confirm all my reversal patterns for small bar. Also has anyone come up with a algo to tune oscillators like stochastic to bottoms on a trend, i've looked around but haven't found anything. // AN INSIDE BAR if ((High[ 2 ]-Low[ 2 ])/point >= 70 && Low[ 1 ] > Low[ 2 ] &&