Marc Boggs / Publications
Codes
ScalpWiz 9001 for MetaTrader 4
Trades on price spikes around important financial announcements
Forum
Automatic Validation Failed - Using wrong period
I'm trying to submit an EA that only operates on the M1 period, but the automatic validation always fails because it is testing on M30, H1, and Daily periods. I even have ChartSetSymbolPeriod(0, NULL, PERIOD_M1) set to force it to run on M1 and redundant code to return in OnTick if the period is
FileOpen issue
int handle = FileOpen (TickFile, FILE_READ | FILE_CSV , ',' ); if (handle < 1 ) { string strErr = Error( GetLastError ()); Print ( "Cannot open file " + TickFile + ": " + strErr); return ( false ); } I'm having a problem opening an ANSI csv file. The file
Error modifying trailing stop and stop orders
This has been bugging (no pun intended) me for some time. I created an EA that performs quite well on price spikes, but it sometimes cannot modify the order to set a trailing stop or move the stop order which is set to 30 pips in this example. I've tried other values and still run into the error
Invalid Trade Parameters on BUY_STOP
I'm testing an EA and I occasionally get an error when opening a buy stop or sell stop . I am setting the price at 30 pips above the ask, which should be valid. I have used MarketInfo(Symbol(),MODE_STOPLEVEL) to get the allowed stop value and still get this error on occasion. Can anyone tell me
iMACD fast period/slow period values
I RTFM... and searched... But, what are the values for fast period/slow period for iMACD. I'm looking at the MACD Sample.mq4, which seems to be optimized for H1. Fast period is 12 and slow period is 26. 12 and 26 what? MacdCurrent = iMACD(NULL,0,12,26,9,PRICE_CLOSE,MODE_MAIN,0);