MQL4 and MetaTrader 4 - page 203

I am testing some EA's but I do not know what is and how to set the "magicnumber". What determine wich magic number to use? Do I set the same magic number at one currency pair at different timeframes? ornot? Do I set the same magic number at different currencies? What happens if a set thesame one...
I like this indicator, but I want to have trades start from the first bar of the signal and there is repainting occuring.. If I am going by one period, 20, and the firstbar repaints, would it be possible to reprogram a heiken ashi to no repaint on the current bar?  Some heiken ashi indicators have...
  TRIX indicator  (5)
I just recently started playing around with MT5 (I live in the U.S. so my options are greatly limited as to brokers who use MT5). I found an indicator in there called TRIX. And I really like it. So I took upon myself to try to convert the MT5 indicator to MT4. I've made modifications to make it
I wrote an Expert Advisor and everything works well except for one function: void OnTick () { //My stuff... if (DayOfWeek() == 6 ) { CloseTrades(); } } void CloseTrades() { for ( int i = OrdersTotal (); i >= 0 ; i--) { if ( OrderSelect (i, SELECT_BY_POS) == true ) if
I keep on trying to make Histograms in a separate chart for example say in Stochastic I want to draw histograms between the D line and K line however the histograms drawn are based from Zero and the Value that I want. is it possible that I make my histograms to lie between the D and K lines only
Hello im new here on mt5 forum, not sure if this is where im meant to be but cant find the Mt4 forum, Ive been using and programming Mt4 for quite a while, now installing to a new computer and the Mt4setup.exe file is installing mt5 instead which is just wierd. Ive tried downloading the mt5 setup to...
Hello dear friends. There is a system I have been following for a long time and I want to convert this system to a robot. is there anyone who can help The rules are as follows; * The system will open buy or sell in triple touch. (I added in the pictures) * There will be stoploss and takeprofit
Hi guys, Below is the code of Keltner MTF indicator. Can someone tell me if this code repaints? I am also trying to monitor it visually - but a confirmation would be great. Thank you. int start() { int limit=1000; //+++======================================================================+++ for (
  EA Entry Only  (2)
Anyone can help me to solve my EA Problem Not Open Sell, and to many order. Thanks alot int start() { if (( iFractals ( NULL , 0 ,MODE_LOWER, 2 )< iMA ( NULL , 0 , 10 , 0 , MODE_SMA , PRICE_CLOSE , 0 ))) OrderSend ( Symbol (),OP_BUY,Lots,Ask, 3 , 0 , 0 , "BUY" , 0 , 0 ,CLR_NONE);
I am trying to convert an indicator I found on tradingview to MQL4: ============================================== BullTrend = (close - lowest(low, 50)) / atr(5) BearTrend = (highest(high, 50) - close) / atr(5) BearTrend2= -1*BearTrend Trend = BullTrend - BearTrend
Hi guys :) I am lookin for an indicator with following settings: - minimum wick size (point and pips) - push mobile alert (on/off) - desktop sound alert (on/off) - mark candle (under wick - green arrow / abowe wick - red arrow) Thank you for inforation how to crate or where i find this indicator
[Deleted]
  Why is access to www.mql4.com blocked?  (64   1 2 3 4 5 6 7)
Good afternoon. Here's the problem! I've been studying MQL for a week now, and I've been using this website as documentation. For some reason I cannot access the website at work IP 62.117.70.201 Why? :)
I am trying to check if I already have an order open and if I do, make sure that it is either a long or a short. It seems like instead of my "if" statement checking to see if the bool function is true or not the program is just running the function its supposed to be checking. There are other issues
I have made a EA to get some data and insert it into my sql database but I got this error when I try to insert , the insert function is in a timer . bool insertMt4Finance(){ string queryInsertMt4String; if(userExist()){ string serveur,currency,createdon,login; double
I use tickdata suite . i have noticed there's one ea that can be tested fine using MT4 history quality, but as soon as i tick the "Use tick data" , I can see the ea loading and the green bar moving, however there's nothing happening at all, no trades, nothing in the journal either what could be the
Hi, Is it possible to send emoji or images to Telegram channel via mql4 code? I was trying to send emojis as a string but couldn't get it done. I also want to send colored emojis string msg = "emoji = "+"😃";
  Memory Question  (4)
Is it possible to retain a variable double in memory, that is calculated inside an EA, that will stay in memory when a computer is restarted? Thanks for any help... couldn't find the answer in Documentation or by Search.... I'm thinking GlobalVariableSet() may do it...can anyone confirm this
I am working on building an EA to look for the candle to Close either above or below the BB, and ride it up or down. The additional parameters include: Buy Conditions RSI is below upper limit (70), Slow SMA (45) is below Main line of the BB, Candle closes above UpperBB Sell Conditions RSI is above
I can confirm by comments that this code is calculating the desired values but it violates its own rules. For example, for a BUY, even when Close[0] is less then limitBuy it still closes trades. Even when I am printing the values to confirm. Can anyone tell me why that is? Thanks for your time void
Hi there, I'm trying to get a list of all pairs with a trade active to finally make a table with a "marketwatch" (to show some stuff on a chart) dinamically adding and removing them from the list. I think creating an array is the right way to go. So, this is my logic: - loop into active trades - get
I want to open orders in multiple charts in a giving condition. example in EURUSD chart ,when price above MA10 and MA15 and no orderstotal , open buy orders. after sometime later , in USDCHF chart ,same signal occurs ,need to open next order . Here problem is how can code orders total counts to open
Hello I need to have 2 Fibo Retracement in MT4 with different level. Can I do it by meta editor
  EA CODING QNs  (1)
Hi how do i write an mql4 ea with the following function: 1. open buy and sell together 2: if(rsi gradient is negative(going down)) close buy order, set x pips tp and y pips sl for the sell order else if ( rsi gradient is positive (going up)) close sell order, set x pips tp and y pips sl for the
Hi, If using an EA running on H1, what is needed to use values from other timeframes? I am currently calling the data using code such as this to call it: iClose ( NULL , PERIOD_M1 , 1 ) Still, I am only getting the H1 closing price. Even when running it on Tick data. What am I missing here? Any help
example: tp pips set 532 . it was hit down to 523 pips already but it was not auto close the trade . anyone have encounter this issue before
Hi guys, I has been working on creating simple indicators based on technical indicator as IMA and IStochastic, this two on particular gave me some troubles, not getting refreshed and have to open their base code and compile it. They are not running complex operations, and just using a simple loop to
pls anybody add email and notifications alert to my indicator
Hi, I'm new to programming, so far I have been able to overcome everything but I have been blocked for a month. the indicator stops working for me and I think this is when I try to split 2 buffers. I would be very grateful if you can help me I put a code that does not work for me Thanks #property
I'm new to programming. MQL4 is my first coding language (and only for that matter). I'm trying to write a basic code that sends an alert when either a shooting star or a hammer is formed. I have two questions after putting this through the strategy tester on MT4. First, no alerts have been sent to
I'm a little bit stuck with the function TesterStatistics(STAT_MIN_MARGINLEVEL). The documentation says the function returns "Minimum value of the margin level". What this exactly mean? I thought that the value is the minimum margin level but it seems to me it's not true. If I run a backtest where