Download MetaTrader 5

MQL4 and MetaTrader 4 - page 986

To post a new topic, please log in or register
Hi all how is it going? I have a script here I need help with what I want addid is a trailing stop input, and a input to lock in pips For example lets say I open a trade and go long and my take profit is 50 pips and my trailing stop is 20, and lets say the market reverses on me before the trailing...
Hi, I am new to MT4 and just come across about the EA. Can someone advise to me where and how to select the time frame to test on the EA. Thank
Using the iMA function I can get values for various period MAs just fine. The problem is that they don't match with what the value is on the chart when moused over. What I need are the values as displayed. Here's what I get--- (USDJPY) double fast_1=iMA(Symbol(),0,MA_Fast,10,MODE_SMA,PRICE_CLOSE...
I have problem understanding the concept volume,there are like three definition i 've seen so far .I don't understand if volume represnt any of these definition:1 amount of ticks in a given time period (2)amount of contract transaction in given time period 3)amount of lot in a given transaction,...
Hi, I was wondering if anyone knew of an indicator that placed the bar range (High and Low) of each candle for different time frames one top of the candle. Alternatively, anyone fancy writing one for me. You would save me from a lot of frustrations. Thanks
  itime problem (7)
Hi All i read in Forum for functions of iTime() and did not find what is needed. if somebody can help i have the EA starts the trade on opening of each Bar, 4Hour chart, 00:00, 04:00,............... i want to open trade one minute or 30 seconds after new Bar starts ( the reason is to have some time...
here is No candles data from 12 October to 15 October any person faced the same bug it is Windows Vista in Japanese but on problem on Windows XP in japanese
Hello coders, I'm trying to solve the problem of multiple orders realisation. In this article there's a description of how ordersend function works: " 4.Execution of the function OrderSend(): 4.1. The function formed a trade request for opening of an order and passed this request to the client...
Hi, I am testing my Expert Advision on an Demo Account and realized (with a Print-Message), that the MetaTrader is running the init-Funktion every few minutes, why? What can I do against that?! Lot's of thanks!!
I am still learning to code and I wrote this basic indicator which graphs the difference between the closes plus the volume. The problem is I can't get it to load the historical chart data. I think I am just misusing the loop function but can't figure it out. Thank you for any help....
Hi, could someone pls show me a full, simple code example where he used a custom indicator on a custom indicator? Is it simply instead of PRICE_CLOSE, the name of the buffer e.g. firstiCustom_buffer[]? Or do I have to work with Arrays like this example using iMAOnArray and ArraySetAsSeries? The...
Hi everybody, Does anyone know how can I know if the order i've selected through its ticket number ? Currently i've this :       OrderSelect(GlobalVariableGet("currentOrderB"),SELECT_BY_TICKET);        if(OrderClosePrice()!=0){ But it doesn't work, ClosePrice seems to be always defined. Thank you....
Anyone have any code snippet that will take an array and keep it synchronized to the orders in the orders table? Basically, I have some custom values that I need to track based on the ticket number. I can add into the array with no problem, my concern is the system closes orders based on stop loss...
Hi Would anyone be able to advise on how I can get email alerts setup for when I get a signal for the below: //+------------------------------------------------------------------+ //| SilverTrend_Signal.mq4 //| Ramdass - Conversion only...
I created a chat room for EAs, or any other discussion for real time. http://www.ircforex.com/chat/ Join the "EAChat" room, after you type in your alias.
On the current order screen one has to enter the stop loss as aprice, what would be good if one could enter the stop in pips, forexample 25 pips instead of the price, this would also be handy as a option under the trade tab the amount of pips per stop. Thank you
Hi folks, I want to code a very simple indicator which will print out the result of the following sexy equations : FirstDerivative[i] = (indicator[i] - indicator[i+1]) / ( iTime(Symbol(), NULL, i) - iTime(Symbol(), NULL, i+1) ); SecondDerivative[i] = (FirstDerivative[i] -...
Beginner here. I have different conditions to open 5 orders at different time. However trailing stop will only run after the 5th order is opened. How to code the trailing stop to function like OrderSend()'s take profit? Which is up and running once any new order is opened?
In a function, I want to return several items or an array. Is it possible? Thanks.
Dear All, Here is my personal usage EA code, it run's okay but can't get the stop loss and trailing stop loss to be functioning. Do you mind helping me. If possible please point out where should the instruction for 50 pip stop loss should be placed. extern double lTakeProfit = 10;extern double...
  help me. (2)
I just started using mql4. I made a couple of small trades and evrything was fine. I made a little larger trade and lost about 100 bucks. For some reason it wont let me buy at market or set an order. The link ( which is usually lit up) is now faded so i cant click it. If someone can give me some...
  Help on iMa (1)
Hi When I put MaShift = -3 in the iMA function as shown below, it returns 0 in my EA, when I change the MaShift = 0, it gives a proper reading, funny thing is in backtest, when I use MaShift = -3, the 2 Ma lines are properly showed on the chart windows, and it does shift to left by 3 bar, but...
Hi everyone, I just wrote my first expert but it doesn't work int start()                                        {  MessageBox ("Ive Started");    int counter;  double MAYellow,MAOrange,MARed,GX,MAAve,TnP,SnL;  counter = 0;    for(;;)  {  counter = counter+1;  int ValueOne,ValueTwo;  ValueOne =...
Hi all, I am trying to write a dynamic tradehour.. I need to count the lowest lows of the last five days and find a time for each low for the calculation. Does anyone have any idea how I can do this? Better still does someone have an example line of code I can work from. thanks
Analytics is one of the most important components of trading.Based on analytical data, a trader can decide what operation toexecute, when to do it and what profit could be gained. The MetaTrader5 offers you wide analytical possibilities! Charts Charts constitute a work field for technical analysis....
Sorry for that title, but im trying to get some attentions :) Well, first of all, I would like to say thank you to all of you who commented on my last post regarding my previous EA (Previous Post). It's been a week since then and I coded a new strategy.. It might seem a lame job for you, but for me...
I am new to Forex and I am beginning to like Fibonacci. I am wandering if someone with experience would suggest me some indicators to add to fibonacci retracement to be be able to make more accurate trading. Thanks to all.
  Hi & lo error (6)
Hi all i want to get highest and lowest price of day before i use double HH= (iHighest(NULL, PERIOD_D1, MODE_HIGH, 1, 1)); double LL=(iLowest(NULL, PERIOD_D1, MODE_LOW, 1, 1)); and tried double HH= (iHighest(NULL, PERIOD_D1, MODE_HIGH, 1, 0)); double LL=(iLowest(NULL, PERIOD_D1, MODE_LOW, 1, 0));...
Hi~ I've got a simple problem for using the function DoubleToStr(). Just don't want to get this again ... Source>> //---- double D1 = 1.2345; string S1 = DoubleToStr(D1,3); double ND1 = StrToDouble(S1); Print("## DoubleToStr Test 3 ##"); Print("D1 : ",D1); Print("DoubleToStr(1.2345,3) : ",...
I do have a custom indicator that uses . Generating a buy or sell signal. My Question is how to pass the value of variable 'flag' either 1, 0, or -1 generated in my Custom Indicator to my EA? iCustom returns the currency value of the indicator, but I do need only that the generated flag status is...