MQL4 and MetaTrader 4 - page 802

  Trailing Stops and Trailing Profit  (66   1 2 3 4 5 6 7)
I need to use Trailing Stops and Trailing Profit. My plan: For Trailing Stop: *After reaching a certain profit limit say 10 pips, the Stop Loss will move to 5 pips. Now if that trade retraces back to 5 pips then 'Two Third' of the trade will be Closed. *Remaining 'One Third' will keep Running and
Hi coders, as mentioned in the headline, I developed a short script. Unfortunately it doesn't work at all. Any help is very appreciated! int start()  {//----   int counted_bars=IndicatorCounted();   if(counted_bars<0) return(-1);   if(counted_bars>0) counted_bars--;   int...
external enter a price value, when price reach the value then buy/sell. Problem: 'Ask' - constant cannot be modified extern double Price = 1.0 ;//+------------------------------------------------------------------+//| Expert initialization function...
My broker still uses the older build of mt4 and this is making it impossible for me to run EAs that were built for newer builds. Is there a way to make an EA that was built for a newer build to work for an older build? I hope my question makes sense?
[Deleted]
Hey guys, I am relatively new to the Forex world. I am using the MT4 Platform with Vantage FX and was hoping someone could help me build an Indicator of some sort to help with my following situation: 1. I am trying to establish the average price of pair at any point in time. I.e. (buy price + sell...
[Deleted]
Does any one know what the method as below is ?
An indicator I've used to show currency slope strength has stopped working after the market closed today. The indicator is the type that opens up separately below the main chart. I've used this indicator for months on two different computers and for the first time ever, it has stopped showing...
I define a struct: struct TradeSet {        double IniTgt, IniStp, PTS, PIP;        string Symb, Descr, Full;        int Magic, DIG, BuTckt, SeTckt; }; Now I just want to copy (move within the list) one element : TradeSet arr[];...TradeSet tmp;tmp = arr[i];...arr[j] = tmp But the compiler complains:...
Mt4 not recognize Any Type Of The Imported Indicators,Expert Adviser And Template I Changed My MT4,I Tried various Platform But Still Is Like Before Please Please Assist Me!!!! My Windows Is 7-64 bit-cor i3 Thank You So Much
In the reference of MQL4 I find the basic DataTypes and I can define array of theses types but a reference or pointers to structs is not mentioned there. Can I define an array of references to e.g. struckts and how should I do this? An array of handles has to be defines as an array of int. Gooly
Hi everyone, I'm planning on developing an API that communicates with the mt4/mt5 servers directly. Standalone win32 applications should then be able to use this api to communicate with the server without having to run the metatrader client. I've searched online but haven't found a good way to do...
Hi Guys, Is there any way to get tick's information from the past? I mean I can get price and volume information using iClose(..) and iVolume(..) functions on one minute (M1) level but I'd like to know what happened to the price and how many ticks occured during that very 60 seconds. If strategy...
  To all coders  (2)
Hi all, Recently registered and looking for looking for a weenie bit of advice which I'm sure should be a no brainer for some of you out there. I already have a custom indicator which I'm perfectly happy with that generates buy and sell signals with blue and red dots respectively. What I'm looking...
[Deleted]
Hi, Im very new to a lot of the trading scene so please excuse my ignorance. I have come from the crypto currency world and have become interested in other markets, I was advised a site where i could trade forex http://www.forexyard.com/ I started a demo MT4 account but found that i could not put...
I am fed up of searching on Google and various forums. Any help w'd be greatly appreciated. I have a script which I am attaching to any one of the open charts. I want to make sure the script does not run on two open charts. so, if someone tries to attach to another chart, it should not attach....
[Deleted]
Hello, I download new MT4 platform and I have chart for all pair. However, in the history folder, there are only few hst file. I am not sure how to get or create hst file for a given pair/TF, Could you tell me how to do it? Thank you. SCFX
[Deleted]
i've verified my ea's comparing 509 and 610 results. and now, i have to verify metaeditor 5.887 built versions comparing with 509, metaeditor 610 died. when will this stop? please stop at a point and we can verify our works. change of one letter is risk. and, data consistency in mt4 strategy tester...
Custom indi. run at TF-H4 name is "indiH4". output as picture 1. Custom indi. run at TF-M30 name is "TransH4ToM30". Which get data from "indiH4" too. output as picture 2. Why EABuf7[iH4] at TF-H4 = 3010 but at TF-M30 = 3100 ? please help ? I'm very headache.
Hi,, To calibrate my script I need 1 year data of GOLD and SILVER with 1 minute period. Any help how I can get it ? Thanks
  Boolean and =  (12   1 2)
I have just spent hours trying to find an error in my code. It turned out to be the simple case of using = where I should have put == I don't know if it is common knowledge or not, but the compiler did not pick up on the error. In this example bool a,b,c; a= false ; b= false ; c= false ; if (a)
extern int K=100;extern int D=25;extern int S=45;extern int P=4;extern double Min=1000;extern double Max;double MaxBalance;int Lots=1;double k=1;bool mevcutstr;bool yenistr;int start(){int ticket;double stoccurrM=iStochastic(Symbol(),0,K,D,S,0,0,MODE_MAIN,0);double stocprevM=iStochastic(Symbol(),0,K...
2014.03.08 17:36:11.666 Compiler loading 'C:\Program Files (x86)\MetaTrader - EXNESS\MQL.dll' library failed (5) 2014.03.08 17:36:11.666 Compiler invalid version of MQL engine - 0 instead of 887 how i can i install for many time i boot from usb and delete it and install new version but this msg...
[Deleted]
hello, since the update to MT4 build 6xx every EAs, historical data were moved to the new datafolder located on the system drive. my problem: i have not enough space on this drive for all the historical data i need for backtesting. i need to move them to another location. is that possible? or is...
[Deleted]
Hello, I know many times were posts about these topics, but I my EA did something strange. Assumption: 1. EA switch on at hour example X and should work to hour Y 2. After conditions it makes trade with trailing stop 3. After close trade by trailing stop EA switch off to the next calendar day (not...
You need help with closing orders with your EA? This post is intended for people who don't know or are not sure how to select and close orders. Please understand that there are many other ways to close orders, this is just one way of many. So, here we go : Step 1. Include #include <stdlib.mqh>...
[Deleted]
How to run trading system optimization on predefined entry points? There is a list of Position openings: Symbol, Date, Time, Open price.Needed to run optimization for Position size, Stop loss pips, Limit order pips, Break even. Any suggestions?
  Order selection  (9)
Amongst all the functions listed the OrderSelect is the most confusing. Answers range from time of sending to alphabetical order. I would like to know it from someone who knows it for sure how it works. Here is the scenario. EA has opened 10 pending orders across 5 charts(2 pending orders per...
[Deleted]
Hello, my english isnt the best. I try to generate different EAs to test them on a Backtest. So i want to automate this process. What i nedd is a way to start a Backtest from cmd. You have any ideas for me how to do? Thanks!!
Hi, I would like to submit a request for a very simple EA based on CCI. Please pardon me if my request seems to be very unreasonable or stupid. I would be grateful if anyone can write the EA for me as I have no experience or technical expertise for the same. Requirement: CCI based EA just to open...
I'm getting this warning on this line of code: intCount[intArrayElement++]; Now, I know this gives me the desired affect; it worked in prior builds of MT4. I'm just using an array to count the number of instances of patterns. It's just a warning, but an odd one. Why?