MQL4 and MetaTrader 4 - page 202

Sorry. I'm not sure how to articulate this. Can I add a number to a variable? So if I have a variable named double Wave1. How could I add a number to that to rename and create a new variable named double wave2
Really new to coding. MQL4 is the only thing I'm learning. Someone wrote me a code so that I could play with and experiment with some ideas I have. They did the hard stuff and created variables that represented the swing highs and swing lows on the price chart (H_Price would be a swing high price
Hello we strongly urge you to include items such as "Recovery Factor" and "Sharpe Ratio" in the " Account History Report " in MetaTrader 4. We need such statistics for financial analysis and risk and capital management. With respect
  Better Bollinger Bands...  (330   1 2 3 4 5 ... 32 33)
This is the Metastock code for an indicator called Better Bollinger Bands. Can anyone code it in MT4? Any help would be appreciated. Better Bollinger Bands I pds:=Input("Periods",2,200,20); sd:=Input(" Standard Deviations ",.01,10,2); alpha:=2/(pds+1); mt:=alpha*C+(1-alpha)*(If(Cum(1)<pds,C,PREV));
Hello, Currently, I have configured my EA to send a notification to my iphone whenever a new trade get executed. Can metatrader4 send notification to all my 3 apple devices including iphone, ipad mini and ipad? Because I am required to enter the metaquote ID in the sendnotification area of my...
[Deleted]
Hi all, i need help. I want add to my EA this: If bar is closing (each bar), close position. (EXIT BUY / EXIT SELL), thank you //Close //+------------------------------------------------------------------+ //| Signal Begin(Exit Buy)...
I decided to use the email notification feature for the first time. I opened the Options in MT4 and configured my email address, SMTP etc. Then I pressed the Test button. MT4 said: Message was successfully queued! Look at journal for more information But then I checked my email and received nothing
Hi, i have a ticket number of order and i want to know if the order is open or close i tried the function OrderSelect (ticket,SELECT_BY_TICKET) and its return me true even when i close the order with the " ticket " number
Hi, I'm currently working on an EA which is causing me some headaches... In the strategy tester the EA soaks up all my RAM, something I've never experienced before - and I'm working with MT for quite a while now. This screenshot was taken while running a backtest. Terminal.exe soaks up alle the RAM...
  Label on H_Line  (9)
i am trying to add a label to my H_Line I have tried OBJPROP_NAME AND OBJ_LABEL, but nothing is quite working correctly. if (TriggerLineTrade== "CA" ) {ObjectSet( objNameDes, OBJPROP_COLOR , clrOrange ); ObjectSetString ( 0 ,objNameDes, OBJPROP_NAME , "Close All" );} or i tried OBJ_LABEL
Hi there, Some very simple code below to illustrate a problem I'm having. I have a very simple class with a copy constructor. The sample below creates a new object and then tries to make a copy of that object via the copy constructor whereupon I get the invalid pointer access error/message. What am
I just need that every time you restart MT4 you don't need to reconfigure it ... I notice that when I restart MT4 the "Remove Script" it disappears! I await reply Thanks
Hello All Im new to MQL4 and programming :) i just started to learn, i need to know how can i write an expert to 1) find the biggest body of last 20 candle 2) calculate the size of body i really appreciate if you help me to learn :) Thanks Mostafa
Is it possible to have an EA running that is told to enter a trade if price crosses the trendline named Alpha, for example then manually draw in a trendline later and simply name it Alpha? Could I potentially write the EA so that it enters the trade at that point? If so, does that mean a person
Hello Everyone, Can anyone give me hint for how to get the MACD Histogram values? the bars <Image Deleted>
Hi everyone I want to create a code to check if numbers of bars closing price is below ema line. And this is the code that I came up with. bool PriceReversingDown( int shift= 0 ) { int result1, result2, result3; //result of closing price below ema line respectively to their bar numbers for ( int
let me say after lastclosedorder wait 15 seconds before open new trade so let me say a sell order and a but order is open when sell hit take profit wait for 15Seconds before open another sell order please i need this delay seconds, thanks the code below was handed to me by my teacher but after
Hi, how can i get info about POSITION_REASON at MQL4 ? At MQL5 the function is PositionGetInteger ( POSITION_REASON ) i dont find the function at MQL4
Hello to everybody, I am getting mad in dealing with array passing to a function. I have defined a function called clear(), with the following prototype void clear(string &[],int); and defined in such way: void clear(string &myArray[],size) {} But when I call the clear function  string...
I need some advice for the below code if you please, 1- for some reason, I get a note of "array out of range " in Mt4 expert journal 2- although Period_MA is external variable and I set it to 20; but when I am testing my code by changing for (x=i; x<i+Period_MA; x++) to for (x=i; x<=i+Period_MA ;
Hi I want to make a stoploss strategy using the lowest price of numbers of bars (in my case 5 bars). this is the code that I came up with: int highestPriceShift = iHighest ( Symbol (), PERIOD_CURRENT , MODE_HIGH , 5 , 0 ); int lowestPriceShift = iLowest ( Symbol (), PERIOD_CURRENT , MODE_LOW , 5
Hi, I am back with another question. Do you have any solution to close all stop orders ? I've been searching for a while but still haven't found the answer. below is my Pseudocode if ( OrdersTotal () < 2 ) { //close all pending orders } Thank you very much for spending time to help me
Hi guys, I need this indicator to have an alert every time the bar changes color. (one color is bullish and the other is bearish), attached I leave the indicator, if you can help me <Decompiled code deleted>
Hi A question for MetaTrader Gurus. For a particular symbol, when a trade is closed, I would like to open the new trade with a 15 seconds interval. Any code snippets please? I would like to express my gratitude in anticipation. Thanks and best regards, Long John Silver
can you create alerts , the alerts in alert tab in the terminal i mean , using scripts/indicators
Hi, I just installed my <Deleted> EA. The balance is ready. The smiling face of the EA is up. I checked the expert tap and it shows the EA is initialized. I checked the Journal tap and it shows the EA was loaded successfully. Anybody knows what's going on? Do I have to wait for a few days for the
  Expert Adv. Help  (6)
Hello everybody; i have a robot in my hand. i want to trailing stop in system but i cant do it. is there anyone who can help me? Thanks... //| day open_baris.mq4 | //| Copyright 2014, MetaQuotes Software Corp. | //| http://www.mql5.com |
Hi guys, Today I started up my computer and noticed that my accounts where gone. So first I setted these up again. Next I noticed my most important indicator is gone. So I went to Indicators->Market and tried to add the indicator I use most often. However, I can't attach it to any chart, it just
  Need help  (3)
Hello traders Maybe somebody have Adc Oscillator indicator MQL4 source code
I am trying to count the total lots for all open Buy trades but the EA keeps on going through the loop and does not stop adding the lots together. So in the first round it calculates the total lots correct but then keeps on adding that amount of lots over and over. I want to stop it once it has gone