MQL4 and MetaTrader 4 - page 1464

What is the difference between OrderMagicNumber and OrderTicket? Seem the same to me.
Ocassionally I need to move the stoploss as close as possible to a trade (open, limit or stop). I cannot seem to find the correct procedure to do this. For example with the pair GBPUSD I have tried using MarketInfo(Symbol(), (MODE_STOPLEVEL)) gives 3, MarketInfo(Symbol(), (MODE_SPREAD)) gives 4,...
[Deleted]
Im looking for a Reversal bar up/down indicator for MT4.
Many people may have heard of or even be familiar with the contents of J.L. Dub's book Probabilistic Processes. Chapter VII of the book, devoted to martingales, says that one cannot profit from pure martingales (a martingale is a fair game, i.e. with zero mathematical expectation, which, according
  How about that!!!  (72   1 2 3 4 5 ... 7 8)
I would like to present you an Expert Advisor based on modified Stochastic + ADX works on 5 minute timeframe results after 2 months of work with initial deposit 10000, lot is fixed 10, can be changed independently during the process, StopLoss 65, TakeProfit 150, TrailingStop 20 stochastic parameters
[Deleted]
I've been programming using MT4 now for about a year - watching tic-by-tic and I've finally got a winner. My first attempt out wasn't so successful -- but, it worked; ie., when I bought it bought and when I took profit it took profit - Now, after downloading the latest revision of MT4, my trades...
[Deleted]
  HELP ME  (1)
ESTOY EMPEZANDO A LEER EL LIBRO, Y QUISIERA SABER SI PUEDO CREAR UNA ORDEN CONTRARIA AUTOMATICAMENTE DESPUES DE EJECUTAR UNA ORDEN MANUAL Y COMO PODRIA EMPEZAR EL CODIGO, SI ALGUIEN ME PUDE AYUDAR LE AGRADEZCO. EJM. HAGO UNA ORDEN DE COMPRA MANUALMENTE Y EL EA ABRE UNA ORDEN DE VENTA CONTRARIA...
  Terminate an EA.  (3)
Hi, How can I terminate an EA if certain inputs are incorrect? I do not want to put a conditional return in start() because its still running and catching the error on every tick. I need something that can just stop executing the EA if the input params are incorrect. Is this possible? Thanks, JForex...
[Deleted]
Hi Admin, Where do I find the next page to ad the code?, after I have downloaded METATRADER 4??? Is there anyone who lives in Australia or on the Gold Coast Queensland Australia.. Rgds - George Martin gibman7@gmail.com 61755294087
[Deleted]
HELLO, PLEASE I REALLY NEED HELP FROM PROGRAMMER. SOME ONE ASK ME TO PAY MONEY JUST TO CREAT MY SYSTEM TO EA, I F I HAVE SUCH MONEY I WILL DO IT BUT AM JUST TESTING THIS SYSTEM ON DEMO AND NEVER GONE LIVE YET, I NEED AN EA FOR IT, PLEASE HELP ME . THE SYSTEM AS FOLLOWS: Place two pending stops BUY...
[Deleted]
Hi there, I downloaded MT4 and created a DEMO account. Then I downloaded an EA for MT4 an tested it with some combinations on the strategy tester. Then I signed up for a LIVE account. And now the strange thing: When I try some strategies (with same values/settings as in my DEMO account) I get TEN...
[Deleted]
PLEASE I REALLY NEED HELP FROM PROGRAMMER. SOME ONE ASK ME TO PAY MONEY JUST TO CREAT MY SYSTEM TO EA, I F I HAVE SUCH MONEY I WILL DO IT BUT AM JUST TESTING THIS SYSTEM ON DEMO AND NEVER GONE LIVE YET, I NEED AN EA FOR IT, PLEASE HELP ME . THE SYSTEM AS FOLLOWS: BASICALLY ON DAILY CHART Place two...
pls can anyone help me this powerful ea open trade daily if price is above pivot point then it open sellstop order on pivot point value and take profit on support1 and stop loss of 100 if price is below pivot point then it open buystop order on pivot point value and take profit on resistance1 and...
[Deleted]
  Help Me!  (2)
Hello All, I encountered a problem. I got error code 4200 when I used ObjectDelete to delete an object. I don't know why. Why cannot I delete an object? Can anybody help me? Best Regards, szfishing
[Deleted]
Hi all, I'm beginer in forex trading. Please tell me if someone knows EA wich works to micro account. I need your help guys. Thank's.
  Feedback on EA  (2)
Hi, after some testing I've set-up an EA that seems providing interesting performances. Attached the results of backtesting over 1-month period (it is very similar on other months). As baseline the EA uses 0.1 Lots quantity. I would really appreciate some feedbacks and suggestions on how to improve...
Hi. I want use a simple code for checking out if market  is under or not certain price-range criteria, into an expert advisor, tick based (checking the values tick by tick), utilizing the simple iHighest and iLowest function, with the  timeframe and shift-bar in-function options. In particular i...
[Deleted]
I am looking to write a program that will run along with MetaTrader. It will allow for one to trade out a main account, which will really be the sum of several smaller accounts. However, this will allow for me to be able to trade quickly and have the profit/losses spread acorss the smaller...
[Deleted]
Hi, I want to Buy or Sell orders at the bar open.What is the logic behind it. ???
can some help me with this trialling stop it does not trail void start() { //---- check for history and trading if(Bars<100 || IsTradeAllowed()==false) return; //---- calculate open orders by current symbol Print(TrailingStop); int cnt, ticket, total; for(cnt=0;cnt<total;cnt++) { OrderSelect(cnt
Hi Traders, I have some code ( I didnt write it) that attempts to determine a trades level in respect to the stages I use to perform a partial close. It attempts to count Order History Records, as a way to determine at which level the open trade is currently. It's quite messy and not fool proof....
The following function will close ALL Open positions-- void closeAllPositions() { while(OrdersTotal()>0) { OrderSelect(0,SELECT_BY_POS); if(OrderType()==OP_BUY) OrderClose(OrderTicket(),OrderLots(),MarketInfo(OrderSymbol(),MODE_BID),999,CLR_NONE);...
[Deleted]
I have heard this indicator to be very effective,but cant get it,pls if any one has a link to it,or any other good indicators dat work well on spotting quick and good trend entries and exits on d daily,i will be grateful!!Cheers.
[Deleted]
Coming from thread https://forum.mql4.com/21235 a Discussion on double arithmetic conditional relationships and HW/SW dependencies... I have run into a problem with the MathCeil() function to determine the correct percent of lots to return to caller for a percent 100. For some reason ( double...
As a safetymeasure I call this early in the Start function: //---------------- SaveAccount ------------------------bool  SaveAccount() {   if( AccountBalance() < BalanceCutOff ) {   Alert("In order to protect the account ", WindowExpertName()," has stopped trading.", " Balance: ",AccountBalance(),...
Hello guys! I have a problem trying to use this library. I put them in metatrader\experts\library I correctly define the path for the .def file ... but my EA print on the register this error: -65495 What can be the problem? And, most, how to solve it? Is it possible that the .def file can be...
[Deleted]
I'm currently using the below function to determine lot sizes. I'd like to make it so that users can use a risk %. How can this be done? double CalculateLots(double Lots) { double Margin; Margin = AccountFreeMargin( ) ; double Hasil; double MLots ; Hasil = Margin/1000; MLots = MathFloor(Hasil);...
  Vesion 5  (1)
I would like to see what you are adding to version 5 of MetaTrader. Is there any documentation that does this? Bill
Hello coders, I have tried to add a signal line to the Osma indicator. It does not work. Please correct the code. Thank you for your help!
Is it possible to create an HTML table in the MessageBox or some other way? I want to have a shortcut where I can add a table with specific stuff I use to look at every now and then.