Meister_Propper Posted September 23, 2009 Report Share Posted September 23, 2009 Hi folks, could somebody add a newsfilter to the following EA, please? ^:)^ Here is the EA: hxxp://www.fileuploadx.de/229821 Here are some codes which may help: This code is for FFCal indicator. Code: extern bool NewsFilter = true; extern int MinutesBeforeNews = 10; extern int MinutesAfterNews = 10; extern bool IncludeHigh = true; extern bool IncludeMedium = true; extern bool IncludeLow = false; extern bool IncludeSpeaks = true; int MinutesUntilNextEvent,MinutesAfterPrevEvent; bool TradingTime; datetime Time2,Time3,Time4; FFCal Indi: http://www.file-upload.net/download-...FFCal.mq4.html This function to check if trading is permitted: bool NewsPeriod() {if (TimeCurrent()>Time4 && NewsFilter) {MinutesUntilNextEvent=iCustom(Symbol(),0,"FFCal", IncludeHigh,IncludeMedium,IncludeLow,IncludeSpeaks ,true,true,1,1); MinutesAfterPrevEvent=iCustom(Symbol(),0,"FFCal",I ncludeHigh,IncludeMedium,IncludeLow,IncludeSpeaks, true,true,1,0); if (MinutesUntilNextEvent!=99999 || MinutesAfterPrevEvent!=99999) {Time2=iTime(Symbol(),1,0)-(MinutesAfterPrevEvent-MinutesAfterNews)*60; Time3=iTime(Symbol(),1,0)+(MinutesUntilNextEvent-MinutesBeforeNews)*60; Time4=iTime(Symbol(),1,0)+(MinutesUntilNextEvent+M inutesAfterNews)*60;}} TradingTime=(TimeCurrent()>Time2 && (TimeCurrent()<Time3 || TimeCurrent()>Time4)); return(TradingTime);} Maybe this could be used, too: http://www.forexsharing.com/457178 Thank you very much for your efforts! I would be deeply grateful if somebody could do that! Unfortunately I can´t code. :( Best regards! Quote Link to comment Share on other sites More sharing options...
Meister_Propper Posted October 13, 2009 Author Report Share Posted October 13, 2009 Re: [REQ] Newsfilter for SWR Grid EA Hi folks, could somebody explain the different logics of that EA? :?: I have used the default settings so far but I´m very interested which other logics are possible and how do they work. Thank you for your efforts! Best regards! Quote Link to comment Share on other sites More sharing options...
ryujin Posted October 15, 2009 Report Share Posted October 15, 2009 Re: [REQ] Newsfilter for SWR Grid EA Hi, Can someone upload the EA again. Thanks Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.