MQL4 and MetaTrader 4 - page 1596

[Deleted]
Hi, I was wondering how to change the inputs to your Expert Advisor without completely restarting the Expert Advisor. For example: extern min_to_stop= 30; Lets say I have a variable(min_to_stop) that counts down time and stops trading for the EA. If have had the EA running for 20 minutes. Lets...
  double MathRound  (1)
Hi, I was woundering if it is possible to round a number like this: 0.123134234 would become this 0.123 0.756524523 would become this 0.756 12.93453452 would become this 12.934 thanks a lot,,,
I am writing a DLL where I need to keep information between calls from MT4. As a result, I allocated Thread Local Storage (TLS) in DLL Main. In tester mode, the DLL functions properly. The TLS retains the information stored between calls. In real trading mode, however, the DLL can find the TLS (same...
I put a variable right after extern variable comparing to in init() function? Let say we have a bool variable "Trade" Is there any difference if we put it here : #property copyright "Metaquotes" //---- input parametersextern int Lots = 0.1; bool trade=true; comparing to here : #property...
[Deleted]
Why does MACD Sample Expert only opens one trade at a time? I have the MACD sample experts running on multiple pair, but only one trade is opened at a time. After doing some research it seems adding an exclusive Magic number to the code could solve this problem. But how do I do this, please help
[Deleted]
Please help. Trying to use this expert in reverse. I want it buy when a sell signal is generated and sell when a buy signal is generated. Also how can I use it on multiple pairs? Seems to only open one trade at a time! B.S //+------------------------------------------------------------------+ //|...
please can anybody tell me how i could get an step by step guide to create an expert advisor. shold be possible to understand for absolutly beginners like me. best would be in german, but english is also fine. r can somebody tell me, if there is any website or person can programm an expert advisor...
[Deleted]
I am very newin forex, in my order my t p was 1.9589 my s lost was1.9580 at price 1.9586 with sell limit but after clicking it shows invalid s/l or tp. can you enlight me on where i was wrong
[Deleted]
Hi everyone I know this is probably a simple question but how do I set up a few options to open or close positions? Example: I want to open a long position if RSI crosses above 30 or if RSI crosses above 70. And then close the order if RSI crosses under 70 or crosses under 50. Basically the question...
Hello, Is there enybody who could help in rewriting the Ehlers sinewave indicator in MQL4? This is the code in Easylanguage (Tradestation). Thanks! -------------------------------------------------------------- Inputs: Price((H+L)/2), alpha(.07); Vars: Smooth(0), Cycle(0), I1(0), Q1(0), I2(0),...
[Deleted]
Is there a way to exit out of an EA from withing the EA itself? I'm not talking about exiting the current iteration of the start() function, but forcing the EA to remove itself from the chart..thus forcing the deinit() function to run?
[Deleted]
I'm working with an EA for testing a series of functions, but I only want it towork one trade with each execution right now. How would I have the ea automaticallyend itself? I tried calling deinit() from start, but that didn't work. Is therea way to do this? Thanks in advance. Nick
[Deleted]
Hi! I´m looking to know if i open more than 20 Meta traders at Windows XP, each one with a Expert Advisor working at ALL Pairs (19). I will need a good Video Card VGA? Or any cheap 128 oe 256Mb can handle? Thanks.
Hi, I need help with this code: double v[5] = {iRSI(NULL,240,14,0,0), iRSI(NULL,60,14,0,0),iRSI(NULL,15,14,0,0),iMA(NULL,60,14,8,MODE_SMMA,PRICE_MEDIAN,0), iClose (NULL,15,0)}; I got the following errors: '240' - variable expected ')' - unbalanced right parenthesis Can anybody tell me why? thanks
[Deleted]
  One open/One bar  (3)
Hello I would make this: In expert advisor,when I open an Orders,then close this in One bar,do not open new orders in this bar,wait for the next bar. (One open/One bar) Thanks Sorry for my English.
Hi I'm new to MQL4 and am hoping someone can help me with this issue I'm having. I've written an EA and once it has been setup and is running I caanot bring up the properties dialog box to change settings. I was under the impression you could right click select Expert Advisor and click on Properties...
[Deleted]
Hi, I wondered whether anyone can shed some light on this problem I'm experiencing with istddevonarray(). If I calculate the standard deviation for a set of prices held in an array in MT4 I get a completely different result compared to calculating the STD in Excel using the STDEVPA function and...
I want to open a pending order with the price= Ask + 20 pips. I use: OrderSend(Symbol(),OP_BUYLIMIT,LOTS,Ask+0.0020,0,0,0,0,0,0, DarkOrange ); But I get a GetLastError() = 130, which is an Invalid stops error. What is the problem? Thank
WHAT DOES THIS MEAN? is it problem with my code or the server banned my EA because of sening signal too frequently?
[Deleted]
can someone give me example of code that create some window where i can put some values and later a can use that imput in my expert advisor. thanks
  Become an Author!  (22   1 2 3)
MQL4 Community is being updated at the moment in order to allow all visitors writing of articles for remuneration. Updating is planned to have been completed by the 1st of May, 2006. All articles about auto trading or programming in MetaQuotes Language 4 (MQL4) will be accepted for publishing. Every
[Deleted]
Can anyone point me why my EA generates an error 130 which is invalid stop loss for this particular trade (and every other shorts i'm trying to OrderSend) Here is the screenshot of my trade: http://img231.imageshack.us/my.php?image=60364059ls0.png Here is code for EA:...
  Adding Time  (2)
If I have a full date time string and I want to add two hours to that to come up with a new date time string, is it possible to do simple arithmatic, or must I parse , convert, add, reconvert? An example would be helpful. Thanks
Attention! Starting from the 29th of February 2008, client terminal builds under 207 will not be supported anymore. This limitation is intended for acceleration of traders' upgradingto the latest versions of the terminal in order to decrease serverloading and, correspondingly, to produce fewer...
I recently downlaoded the Fractal ZigZag EA and wanted to see why it is doing sowell. After playing around with it and at the end removing everything in the EAexpect the buy command it made that amount of money. I used the following settings: GPBUSD daily Open prices only TakeProfit = 25;...
404 The page you have requested does not exist Please check the path for errors and try again or use search page
[Deleted]
Hi, I would like to make an EA to handle opened positions in a specific pair. I can have many opened orders in both directions, each with different lot size and opened at different levels. I would like to calculate which is the breakeven level resulting of the current situation. Anybody who can help...
hi, take as instance the fibonacci object. how it does fix its fibonacci level in the far right of the windows? those levels (23.6,38.2, 50, 61.8) act as labels, but I don't think they are labels. how can I get the time value for that exact coordinate at the far right window for those fibonacci...
 i have read that ticksin mysql and i know that , insert record to mysql iseasy , could anyone please give a example to show how to query records from a database,use "select ..." .  thank you .
[Deleted]
  coppck
can any one make coppck in mql4 if i give him how it is in metastock?