Watch how to download trading robots for free
Find us on Twitter!
Join our fan page
Interesting script?
So post a link to it -
let others appraise it
You liked the script? Try it in the MetaTrader 5 terminal
Experts

Close At Time - expert for MetaTrader 4

Algofxsolution.com | English Русский Deutsch 日本語
Published by:
Algofxsolution
Views:
16521
Rating:
(19)
Published:
2015.12.02 12:48
Updated:
2016.11.22 07:32
closeattime.mq4 (14.69 KB) view
Need a robot or indicator based on this code? Order it on Freelance Go to Freelance

Close At Time is an Expert Advisor for MetaTrader 4 trading platform, that closes open positions or deletes pending orders or both. You can also specify how it should be closed — by symbol, magic number or ticket number. And the last one is time when Expert Advisor will close selected orders. Time is meant local time of computer. Expert Advisor has also integrated error description for cases when there is some problem while closing individual orders.

EA is built on idea that it has to be done. It means that if there is an error while closing order or position, EA will try it again on next tick. It has also small problem when this idea is applied. Other trades, opened after selected time and satisfying selected conditions, are closed (EA is not stopped). But it doesn't violate basic idea.

Input parameters:

Close settings:

extern bool bAllClose = false; //Close All
extern bool bSymClose = false; //Close by Symbol
extern bool bMNClose = false; //Close by Magic Number
extern bool bTNClose = false; //Close by Ticket Number
extern bool PO = false; //Close Pending Orders
extern bool MO = false; //Close Market Orders
extern string TimeToClose="YYYY.MM.DD HH:MI"; //Local time to close

Close parameters:

extern string SymClose=""; //Symbol to close
extern int MNClose = 0; //Magic Number to close
extern int TNClose = 0; //Ticket Number to close

Cidomo_v.1 Cidomo_v.1

The strategy of this EA is daily breakout which is compare previous high or low previous day candle then place a pending order for breakout.

Millenium Code Millenium Code

This program is a basic version of the original code of relatively simple system Millenium.

Levels with Revolve Levels with Revolve

EA opens trades from support and resistance levels, which were set by a trader, and revolves them at another levels.

ZigZag Dual Buffer ZigZag Dual Buffer

This ZigZag indicator uses dual buffers to store high and low points.