MQL4 and MetaTrader 4 - page 301

Hi, I'm currently situated in Adelaide, but the Forex scene is pretty quiet and also I'm having trouble finding people with programming skills. If there's anyone here from Adelaide or Melbourne Australia I wouldn't mind hearing from you. Cheers
what will happen when equity goes to zero ? Balance is 7k+ Positions are hedged. Note: Margin Level is not displayed/not shown by MT4 apps because BUY and SELL lots are equal (hedged) Note: Many other positions are not shown on screenshot
Hi there guys. Does anyone know the algorithm used by the strategy tester in MT4 to simulate ticks based on price bar data? Regards
hi guys i try to write text under or up a candel i try with this code but write in left up corner o_O ObjectCreate ( "Demade" , OBJ_LABEL , 0 , Time[ 0 ], (Low[ 0 ])); ObjectSetString ( 0 , "Demade" , OBJPROP_TEXT , "GAOGA" ); ObjectSetString ( 0 , "Demade" , OBJPROP_FONT , "Arial"
Hello Everyone. I'm new in coding. I'm trying to set up an EA. even if it seems to make good profit when I check the journal I get error 4108. And the screen is full of orders and modified orders as I use a trailing stop. Can someone help me with this issue? I will attach the code in the forum so
hi everyone i have an custom indicator with lot of graphic object whenever i'm suing it in script with iCustom all graphic object appear in the chart i want to know how to prevent this custom indicator object appear in chart thank you
Can't figure out if strategy tester as well as optimization is considering margin requirements for lots and considering it as draw-down against the equity? Seems like it should however leverage is never specified in the test unless you are using tick data from a reputable source which then would...
I am struggling to understand why all of a sudden my strategy tester wont run on the particular settings i am using. I am getting the error "not enough money" however my leverage is 1:500 and to open 1 lot it requires £200. on a 500GBP account i should be able to open 2 lots at a time leaving 100GBP
Hi! This weird thing keeps happening to me while trading and I cant get rid of it. It displays the candles totally wrong, today I logged in a demo account just to show you this. Maybe one of you went through this on your mt4 account and can help me. So basically, look at my profit in the bottom
hello. actually i'm almost new to mql4 programming. i have a angle indicator which is using MA and inside other EA i want to call this angle indicator and want to read angle value so i tried iCustom but every i tried all failed. following is ma_angle source. and this is icustom code what i tried
  Hello world  (4)
Hello world. Hello world ()
Hi, Please, I need your help in code for adding Pending Stop Orders to an EA in MQL4. How can I open a stop order depending on the last trade that entered the market? Let's say I open a trade 0.01 BUY but and I want the the EA to take that trade and place a new order in the opposite direction with a
Hello. As soon as the sum of my open buying positions reaches $ 100 profit, including all fees, I want to work closeallbuying() void. I was unable to prepare a code that could work for this. I would be very happy if someone could help me
Hi there, I am new to MQL4 programming and came across the following practice problem online: create an EA which checks the previous N = 10 candles and if PSAR is consecutively above than iOpen() for all these N = 10 candles, open a sell position; if PSAR is consecutively below iOpen() for N = 10
Hi friends, I come across these function in MQl4. ChartTimePriceToXY() and ChartXYToTimePrice() While I was doing one of my coding exercises, I tried to convert a price say 1.0850 to X and Y coordinates and convert the resultant X and Y coordinates back to the price, expecting to get back the
Hello, was wondering if someone can help code this concept into an EA for me. Applies to any symbol, any timeframe. Unfortunately I just don’t understand coding, however I do know how to apply it! Default Parameters (but adjustable) Lot Size 0.01 2
Hi, I've got this EA here that uses the MA and stochastic to enter trades and has a set TP in pips but I'd like to add an orderclose function that would close the sell trades when the stochastic goes below 20 and close buy trades when it goes above 80. Unfortunately when I tried to do this the order
  Bug ?  (1)
i use iCustom to compute an indicator with a varying period. i use doubles for the period, for precision, but if I put the variable directly in the iCustom command line, it bugs and loops forever. if I use "(int)variable" then it doesn't loop it took me a while to find that error could it be
Hi, I have an indicator on multiple open charts in MT4. The indicator fails sometimes on reinitialization after a symbol change, but only on the weekly chart for this symbol. This is very repeatable. The other timeframes/charts are fine. This happens always during OnInit() when EventSetTimer(1) is
I want to scan indicator buffer (from current bar to old bar )with using iCustom code. for ( int J = 0 ; J < 1000 ; J++) { double up = iCustom (Fx_Symbol,TIME_FRAME, "indicator file" , 0 ,J)!= EMPTY_VALUE ; double dn = iCustom (Fx_Symbol,TIME_FRAME, "indicator file" , 1 ,J)!= EMPTY_VALUE ; if
hi every one I define an extern in expert: extern int Risk I want user just can insert numbers from 1 up to 3 like 1 1.2 1.3 , ..... 3 and couldn't insert number less than 1 or bigger than 3 How I can do it? Best regards
int OnCalculate ( const int rates_total, const int prev_calculated, const datetime &time[], const double &open[], const double &high[], const double &low[], const double &close[], const
is backtesting on open bar reliable? How does MT4 know when SL or TP were hit
Hi Experts, I need your valuable help on the following peace of code, I am trying to modify an open order as part of my EA but during the back testing it does not seems to be working. I have tested with several pairs, time-frames and time range but it does not seems to modify any order. Here is the
//+------------------------------------------------------------------+ //| mn Period Boxess + //+------------------------------------------------------------------+ #property indicator_chart_window #property copyright "mn" extern int
Hi All, Hoping there's something really obvious someone can point out to me. I have an EA that performs perfectly on backtests, and almost perfect on live trades - except for one key feature. At 2pm the EA analyses whether the current day price range is within the previous day price range. That
has anybody got an Mt4 virtual server running under Windows 7 family premium ? I started creating one and it hung at the stage in the screenshot https://www.screencast.com/t/6hbYA0noZgzE
Hello! Below is my lines of code to auto create VLine on other visible charts when I manually create it on the current chart. I don't know where I have made a mistake. Please I need your help. Thanks in advance. int OnInit () { ChartSetInteger ( 0 , CHART_EVENT_OBJECT_CREATE , 1 ); return (
[Deleted]
Hi, exist some "easy" order in MQL, which reverse my positions at the same price? Buy to Sell or Sell to Buy (always same size) OrderClose and next OrderSend (new reverse position) is slowly, I get slippage. Thanks. Endy
void OnTick () { double PRICE = 100 ; if ( OrdersTotal ()== 0 ) { int buyticket1 = OrderSend ( Symbol (),OP_BUYSTOP, 0.01 ,Bid + (( PRICE * 2 )* _Point ), 3 ,Bid-(( PRICE * 2 )* _Point ), 0 , NULL , 0 , 0 ,Green); int buyticket2 = OrderSend ( Symbol