MQL4 and MetaTrader 4 - page 1230

Hi, I want a script that enters the market after X pip (like 25pip) and leave the market at X+1pip+spread or at X-50pip+spread. The script should be able to take both long and short positions. I also want it to enter and leave the market on negative trend, is shall not react on a negativ trend...
[Deleted]
Dear Fellow Traders, Everyone related to Stock Market is always focused on thegoal of how much they can make buying/selling a stock, they forget to concernthemselves with how much they risk loosing. Is it true that “The secret to great wealth in the stockmarket, is not big gains; its small losses”...
hi everyone does anybody have a simple piece of code that I can insert into my EA that will: 1. scan all open positions 2.determine if trade has reach predefined sl / tp 3. close trade accordingly btw, Im a ex cobol programmer and still new to mql4 thanks
Hi I see that mql4 has ArraySort and ArrayBSearch but all these only work on the firstdimension. Here is an example array and what I want to accomplish array[0][0] = 100; array[0][1] = 1; array[1][0] = 400; array[1][1] = 2; array[2][0] = 200; array[3][1] = 3; I want to get the highest value 400...
Now is the perfect time to start a new MQL5 / Forum.....Very little of what's here on MQL4 will be of any value in MT5
[Deleted]
guys and girls I am novice programmer and would really appreciate some help. I am trying to close an order if certain conditions are met using the following code if (orderopen == 1 && OrderType() == OP_BUY && FMA < SMA) { CloseOrder(); } using alerts I notice that...
Can someone please remind me how an EA can recognise the start of a new bar. Is it that if (Volume[0] == 0) // means start of a new bar
Hi, Just spotted a post regarding a Tetris game written in MQL5... Brilliant... SOmething to ease the monotony of "sideways days" :-) OK - The main reason for the post is this - I'd like to get my hnads on MQL5... Looks great... downloaded the tetris code & had a quick look. So much better than what
total  = OrdersTotal();    if(total<1)      {              if(isCrossed== 1  )//jezeli jeden to daje sygnal buy i zajmuje dluga pozycje                    {  //1                                  //preferowana cena zamkniecia,roznica,stop loss,take profit                        ticket1=...
Hi all: I am too new to MQL4 programming. Having problem with my program. I do appreciate if anyone can assist me. 1. I wish to find the before price of the current BID/ASK price. I do not know which code shall i use. Price_OPEN or Open[1]? The before price and BID price is within then same bar. 2....
[Deleted]
Can You add year period to MT5 ? I need year period!
[Deleted]
I use 'ALLFramesTrend.mq4(picture below)' on my trading. Sadly, this indicator's bar appears next chart bar as if there is on previous chart bar. For example, I want the indicator's bar appears point B(previous bar), but actually appears on point A(current(next) bar). -if current chart bar is A,...
[Deleted]
HI! When I use OrderSend it makes a lot of trades but I want to make only one per day, means that a trade to be done everyday. Tried different methods but no result. Please help.
Visual Investors FX Club - Demo Statement The above summary shows the performance of the Visual Investors FX club's (ViC) demo account for the past 3 weeks (From the End of September to date). The Visual Investors FX Club is opening its doors to 10 more additional members. If you are interested...
[Deleted]
hi for example if i want to keep the value that my position is closed and use it later what i shoud do? thanks
[Deleted]
Does anyone have a snippet of code that will remove orders based on a certain amount of time passing by? I know orders can have an expiration but I want my EA to remove an order after two bars on the 15 minute chart. Any help would be greatly appreciated!! Daniel PS: I did try searching the forum
[Deleted]
Hello, Does anyone know if there is function to automatically populate the horizontal line description? I wrote an indicator to plot support and resistance lines based on extern manuially entered values. My goal is to populate the horizontal line description with "Alert_0" so the alerter indicator...
Hi everyone, Looking to buy in this scenario. The price has moved to the bottom of the last twenty days. This code being: (Ask<(Low[iLowest(NULL,0,MODE_LOW,20,1)])). What I am looking for is the code, that after the price has reached this area, I wish to enter a limit order to buy two pips above...
What's the best away to remove zeros (or any value for that matter) from a 1-dimensional array so that all the other data shifts down? For example, lets say I have the array: double array1[5] = {0,5,0,3,4}; and what I want to end up with is: {5,3,4} so that the new ArraySize is 3 and all the zeros
[Deleted]
Hello to all! My name is dra and im not a programmer but I really need something programmed for me and was wondering if any of you all have the time and would like to be helpful. What I need done should be simple but then again I dunno you guys have hard jobs! I respect all programmers because...
[Deleted]
hi! how to make a trade if the current time is 13:00? please help...
[Deleted]
Hello, I use a function in order to modify values in a array and i want ot return the modified array. Example : double userFunction(int A, double BufferValue[Size], double B) { double ModifiedBufferValue[Size]; //---- ... modify array value... //---- return(ModifiedBufferValue); } Is...
Hi all, i had a problem with my broker that is not a scam but friday quotes were delayed . Maybe saving quotes in a file with timecurrent and timelocal indexed on a atomic clock. What do you think about this
[Deleted]
  Simple Bug......  (5)
i have this indicator but the sound and the indicator don't work. If you compile it has an error. here is the code as well as the indicator.....I would be very grateful for your time as well as your solution. //+------------------------------------------------------------------+ //|...
Hi, This runs OK, but in the experts tab of the terminal, there is a continuous stream of 'Divide by Zero' errors. Thanks to one and all for any assistance with this (< 8) //+--------------------------------------------------+ //|PipMaker v5 Neo Last Update 06-27-2007 01:05am |...
Okay, I trade with Forex.com for my forex investing. Here is my story. A few month back, I notice listings in my account dissapearring back and forth like it was being edited. And just this week, some of my winnings dissappeared without a trace. Is this emezzlement or what? The small embezzlement...
[Deleted]
Hi guys, i use many parameters in my EA, and when i try to optimize the script using Genetic algorithm i get this error: "Too many passes for optimization. Please try to decrease optimized parameters amount or to increase parameters' values step." Of course i know it will take a lot more time to run...
Hi, anyone wanna modify this function a little ? Its a very useful tool for testing / debugging / visualizing stuff. Problem is that it places multiple Vlines at the same bar (typically on for each tick) and even a short testrun can result in thousands of lines ontop of eachother, which is very slow...
[Deleted]
Hi, I was wondering if someone could 'read' this EA and tell me how it works? I am trying to learn how to read code so that I can also learn to write code. This one I find interesting when I back test but I can't figure out what entry signals it uses. Thanks
[Deleted]
I am writing a EA and test it on history date. I test EA many times and the AccountFreeMargin() function always return negative number now. How can I reset deposit to make AccountFreeMargin() function return initial deposit value? Thanks!