MQL4 and MetaTrader 4 - page 484

Hello, I need to add displacement between the price and arrow 
does any one know why i am getting this error and how to fix it, this is the line, extern int    ProfitTarget         = (AccountEquity()*1.01);
Comments that do not relate to the "Please help with one trade per day code", have been moved into this topic.
I created an OOP-base for Indicators and EA, so that I don't have to use iCustom! What you see is a very simple Mom: Buff2[b+1] = close[b+1] - close[b+1+PER]; Buff1 receives the values that are calculated by the OOP-base. As you can see, the OOP-calculated values are pretty much the same as the...
Hello Why every time I do a strategy tester always appears in the image below. Is there something wrong my Ea.?
  MT4 Vs MT5  (2)
Why do most of the Algo startup using MT4 and not MT5 ? what is the main advantege, still, in MT4 , and why do you still using it ?
Hi guys Why i don't see my EA  indicators  on the chart in backtest ?
Hi everyone, it's my first post and I hope I am not in the wrong forum. Problem is, I just downloaded mt4setup,exe from metaquotes.net but it does not start on my system (Win 10). Same problem with MT5. In the event log I see errors but they do not contain any specific message, maybe someone can...
  Please Help Me  (3)
Dear friends, I am new in EA programming and i need your help please. I want my EA to wait after close last trade and don't open trade until next signal. For example if my EA open last Sell trade then after close as TP or ST wait for BUY signal and don't open again Sell before get Buy signal
(int i=OrdersHistoryTotal()-1,i>=0,i--){ //do something} ...since major CPUs' "count" registers count the "for" loop backward.
In stdlib there is a function called IntegerToHexString that converts an integer to a hexadecimal string. However I need a function that converts a double in MQL to a binary or hexadecimal string based on the IEEE-754 format. The procedure is outlined here: IEEE 754 Standard for Floating Point...
Hello everyone, Where I have "//---" is this a case of the button doesn't exist or, a possible function call if the button is pressed or, released?     if(!Create(0,"FIND",0,20,80,90,HEIGHT,CORNER_LEFT_UPPER,"FIND",FontStyle,Fontsize,BLUE,ALMOND,None,false,false,false,true,0))   {//---      }
Hi guys - can you tell me if this high number in the connection panel is normal. I have MT4 with 10 charts at 15min and 2 offline charts open as well. I have set history bars at 5000. Any suggestions or is this acceptable? Cheers
Hello Is it possible to have one click trading script code ? if not can you let me know have script that not work after click on that! and only run after set values on chart and click for example buy button ? i have script that work immidiately after click on that and i use simple code like this...
Hi I have a number of trading ideas and want to test them by programming an EA. I would like to learn so I can change things as I go. What is the best way courses etc to learn how to program. Do I need a mentor....Thanks
How much could I earn if I rent my cpu i7 3770 for 24 hours?
hi guys. I'm trying to modify an Order, but I always get Error #130. I looked for other texts, but ... Different from this code, it is difficult to understand and apply. So I raise my code. Please let me know based on this code. extern double initial_Lots = 1.0; extern int MagicNo =...
Hi, after I run the backtesting EA get error 134: 2017.08.06 22:23:59.658 2017.08.02 01:47:28  Tester: PrevBalance: 50000.00, PrevPL: 0.00, PrevEquity 50000.00, PrevMargin: 0.00, NewMargin: 118059, FreeMargin: -68059.00 2017.08.06 22:23:59.658 2017.08.02 01:47:28  Tester: not enough money for sell 1...
Hello to eveyone, I am facing a problem, i don't know if there is a solution. I am creating a custom indicator and i want the readings of this indicator from the timeframe H1 to dispalyed in the timeframe M15. For examlpe: if ( iMA(NULL, PERIOD_H1,.....,i)  > iMA(NULL, PERIOD_H1,.....,i)    {...
I need to read a .csv file with a single number (say 0.45365345). Depending of this number the expert will make decisions on trading... I have wrote the following piece of code in the start() function: // Read the file with the probability      int handle=FileOpen("test.csv", FILE_CSV,...
  Global variables  (4)
Hi: In an indicator I've been developing, I need to save 2 variables on changing chart period for use in the new chart. The code below is truncated from the indicator and uses only the OnInit and OnDeInit events. I stripped and simplified it from the main file so I could troubleshoot it. Basically,...
Hi, I'm new to MQ4 coding. I hit some problem when using customer indicator in my EA. I coded an EA that use an existing indicator. When I run my EA, the indicator is loaded in the chart and I'm able to use the buffer of the indicator. See attached 1. I can see from the log that after EA is loaded...
Hello everyone, I need some help to understand what this runtime error means. I have been trying to work it out, but I am making myself very confused about where the problem starts.    CurrAsk= MarketInfo(Curr,MODE_ASK);   CurrBid= MarketInfo(Curr,MODE_BID);   Ticket=60055216;   Price=0.800133;...
[Deleted]
Hi! I would like to smooth CCI 6 indicator with Smooth Length 5, Smooth Phase 100, like here: extern string TimeFrame           = "current time frame"; extern int    CCIPeriod           = 6; extern int    CCIPrice            = PRICE_TYPICAL; extern double OverSold            = -100; extern double...
  Lot calculation  (8)
It's a pleasant weekend. I'm trying to make the Martin Gail lot calculation. If I lose, I'll double up in the front door twice and return to the initial value if I get profits. However, this will result in error 4051. And I don't know if it's okay to solve 4051 or something else. Wait for your help....
Hi Please help I want the ea to open a buy order when profit exceed 20> I've coded this, see below but the code is unreliable( sometimes it works,sometimes it doesn't).  Any suggestions on how it could be improved? if((OrderSelect(gBuyTicket, SELECT_BY_TICKET)==true) && OrderProfit()>20)BuyA=true;
My broker has just informed its clients that as of Monday: "MT4 charts will show aggregated prices of Bank, Non-Bank, and ECN liquidity on all FX from Monday's market open. It is important to note that all orders will be triggered based on the published Bid/Ask price visible in your Market Watch and
Hello Everyone, Here is the code for the ComboBox (MT4). It work on the indicator but not on Expert advisor ? I wonder why ! I have two questions: 1-How to make a ComboBox in the EA ? 2-How to select an option from the ComboBox's list ? Thank you very much #include <Controls\ComboBox.mqh>...
I'm very new at MQL4 and still learning. What I'd like to do is place several text labels at the top right at a certain position for the purpose of adding notations to a chart. This would be for tracking some of the more "fuzzy" variables in trading which are based upon opinion rather than...
What is the easiest MQL4 tutorial you know? I'm following the one at book.mql4.com, but it's slow going. Any favorites or suggestions?