MQL4 and MetaTrader 4 - page 1130

  2 charts in 1 ?  (2)
Hi, I would like to draw eurusd & gbpusd charts in same chart. It is possible with mt4 ? Tx.
Hi, If anyone need. how can i to know the last open trade status ? void LastOpenTrade_function(int nb) {                      for (int cnt=0;cnt<OrdersTotal()-nb;cnt++) {         OrderSelect(cnt, SELECT_BY_POS, MODE_TRADES);              if (OrderSymbol()==Symbol() && OrderMagicNumber()==Magic)...
[Deleted]
why do i get an error when i initialize my stop as double stoploss = .0050;
[Deleted]
i have a strategy but i don't know how encoding it the strategy is open buy position if the price move up then the highest price of the asian session open sell position if the price move down then the lowest price of the asian session the asian session start at 02 am and finish at 07 am please help
[Deleted]
  Ratchet Stop?  (5)
hi Guys, Im not sure if its called a ratchet stop but im looking to do a stop loss that will jump to Break even when 100 pips has been hit and then to 100 when 200 has been hit and to do this up to 5 levels. I have messed around with a couple of ideas and the problem is the SL keeps...
[Deleted]
Hi everyone! How can I get a requote when I am backtesting? And what can I do against it? 2011.08.10 19:31:34 2010.01.12 12:00 EA EURUSD,H4: OrderClose error 138
  i want a script  (2)
hello i want a script who say: if price up of 100 pip, buy position If price down of 100 pip, sell position. it's all if it's possible i take this. thanks
[Deleted]
I'm creating my first scripts. I created an "include" file, that has a function that places an order (int PlaceOrder()), and a script (PlaceBuyOrder()) that calls PlaceOrder() in the included file. It works fine unless I run the script a 2nd time while the "OrderSend()" is still on the screen. The...
[Deleted]
Does MT4 have any portfolio management capabilities, like would it be able to close x% of all open positions in a portfolio with multiple currency pairs with one simple script?
This code works for FX symbols but not index symbols like the UK100. Any ideas what is wrong? int start()  {   if (Period() == PERIOD_H1) {period_no = 1440;}   double hprice=iLow(Symbol(),period_no,0)+iATR(Symbol(),period_no,14,0);    ObjectCreate("highLine",OBJ_HLINE,0,0,hprice);...
[Deleted]
hi i need help with an indicater as per the picture. i need a calculation of the angle of the standard deviation line if possible, or the gradient of the slope might be a better calculation. I have a theory and would appreciate any help possible please...! Gradient A to B line is required....
  current rates  (3)
Do I need to: RefreshRates(); before I do: MarketInfo(symbol, MODE_ASK); My understanding is that RefreshRates() will update Bid and Ask constants, but if you are read them through MarketInfo(), you will receive the newest one and you don't need to use RefreshRates(); So in a nutshell...
[Deleted]
If I had an EA attached to a GBPUSD chart and I want reference the high and low of other instruments 10 periods back (i.e Low[10]) how am I am to do this? Low[10] just gives me low of current symbol and MarketInfo(EURUSD,MODE_LOW) just gives me the low of current bar of EURUSD. I would like to...
What code is required to limit what ASK or BID price my EA can make purchase for. I am looking at PRICE_MODE but dont understand how use the proper syntax. I mnot clear that this is the code that should be used. My goal is to prevent PAIR purchases that are more than a certain price. Thanks in...
Hi, Having a temporary moment of confusion. Lets say I want to sell the same $ amount of EURUSD, EURCHF and EURJPY, lets say $10 000. How do I calculate the lots sizes. I would have thought it's $10 000/Current Price/ Lot size, so for a mini account EURUSD trade: EURUSD = $10 000/ 1.4341/10 000 =...
[Deleted]
Hi all, this is my first post, so please bear with me. I have read through about 8 posts which were similair to mine, but nothing to help me unfortunately. I am trying to play around with the expert advice system and have come up with a simple start function as below: int start() { //Open...
[Deleted]
Very new to mt4, Could anyone help me to create a indicator that will trail a vertical line by say 20 candles.
[Deleted]
  Error 130  (5)
Hi I am a newbie and testing my EA, but if I want to set up the takeprofit level to Ask+50*point I get always error code 130. I wrote an ordersend script to test what the problem is: int start() { RefreshRates(); int Ticket=OrderSend(Symbol(),OP_BUY,0.1,Ask,2,0,Ask+50*Point); if (Ticket<0)...
I want to write a code is based on if last order profit or lost, how can i do that??
I have an MA cross indicator with buffers to show MA crosses. How can I print a label with the price it crossed at just above the crossing area? Is it a case of adding a 3rd buffer? The current buffers use symbols so I am not show how to add a label there.
This is a Good Auto EA ( MT4 ), if you are a programmer please help ( August 2011 Year ) To Use just change the Trade Time will do . This is a Good Auto EA (MT 4 ), But need to have Some Fine tune, if you are a programmer please help . Trailing stop not working . and journal report : 2011.08.05 17...
Sorry for just posting for some crap like this..i'm currently using divergencewiseman1 that i've downloaded from this site, and i've found that its very useful for my trading even in a small lot. Its actually not a 100% winning trading system i had, but i think its ok since the person had a good
Can anyone tell me if there are limits on OR statements? e.g. I run several possibilities in my close statement but it appears that all of the conditions are not read. Is there precedence? /CLOSE SELL         if ( rsiG > 70 ||AO.1H > 0 || rsiD > 50 || rsiD <  30 && SDO.030M > SDO.130M  )...
Any Idea on how to Open a Chart from a Script, or EA. I would prefer not to use SendMessageA( but will if forced. I would also like to control The Profiles and templates from the script in MT4 not 5
[Deleted]
/*------------------------------------------------------------------+ |                                             fracmap_home         | |                                                 Copyright © 2011 | |                                                                  |...
HI, i try to design a function that read all open posiiton and return the position which are on same levels, and returning all the levels in questions. Example i have a buy at 1.3538 and some time after i take a position sell or buy at 1.3538 +/- spread, and 1 hour after i ask the ea to say if there...
[Deleted]
  MACD Line  (1)
Hey everybody, i am using the MT4 and i was checking the MACD to find out that the MACD line is not constructed, also, the signal line is 9 day SMA instead of EMA. is there a way to add the MACD line or change the Signal line to EMA instead Thank you very much for your help Best Regards,
[Deleted]
When I try to use the scripts in MetaTrader nothing happens. I try to execute them from the list also drag to the chart but nothing happens. I use some to close all orders and to buy and sell, but nothing. I have to activate something to use scripts? Thanks for help me. Cristian
I have created an indicator with several double type variables. The values are based off math calculations of pricing information. I want to be able to create trading situations based on the value of those variables in the indicator I created. Do I have to create a separate indicator for each...
[Deleted]
Hi All, I'm new to the forum and to mql4. Have just tried to create a simple ea that I can use in MetaTrader 4. Got a bit of an issue. I'm using MA and MACD as indicators in the ea. But when I Print the ma and macd values per bar, they are different to what I see on the chart after I run the