EA opening opposite pending orders

MQL4 Experts

Job finished

Execution time 27 minutes

Specification

I need an EA for currencies on MT4, which upon activation (without any further signals) opens a pair of pending orders: A buy stop a specific distance (in %) above the current bid price and a sell stop the same distance (in %) below the current ask price. For both of these stop loss and take profit orders are placed. 
Once one of the orders is opened, the other one is deleted. The whole process starts again from the beginning, as soon as the open position is closed or if neither the level for the buy stop nor the sell stop has been reached after a certain period of time.
New orders should only be opened in a defined timeframe (for example from 9 am to 9 pm). The lot size is to be set automatically to a value, so that upon opening of one of the orders a given percentage of the available capital equals the margin.  (10000 € available capital, percentage=40%, margin=4000 €, margin rate = 3,33%, current price(EURUSD)=1,085 => lot size=1,11)

For example:
EURUSD is currently trading at 1,0841/1,0850. Distance for the order levels is 0.001%, Distance for take profit is 0,0008%, for stop loss 0,0004 points. 
=> Order level for the buy stop/long order is at 1.08609 with take profit/stop loss at 1,08696/1,08569.
=> Order level for the sell stop/short order is at 1,08302 with take profit/stop loss at 1,08216/1,08342.
  • If after the waiting period of 90 minutes neither a price of 1.08609 nor 1,08302 has been reached, the orders ar canceled and a new pair of orders is created according to then current prizes.
  • If a price of 1.08609 (for the buy stop/long order) is reached and the position is opened, the sell stop/short order is immediatley deleted. ...and the other way round, if the short position is opened.
  • As soon as the opened position is closed by reaching the take profit or stop loss level, a new pair of orders is created according to then current prizes.


The variables needed are:
- distance of the order leverls above and below the current prices. Input of the variable should be in percent. (for example 0.00085%)
- distance of take profit above or below the order levels. Input of the variable should again be in percent.
- distance of stop loss above or below the order levels. Input of the variable should bei in points. (for example 0.00055)
- the waiting period, after which unopened orders are deleted (in minutes)
- percentage of available capital, that is to be put up as margin. ( e.g. 45 %)
- (mr: margin rate - if MT cant't automatcally determine the margin rate, so that the lot size can be calculated, e.g. 3,33% for most forex)
- earliest hour for opening trades
- latest hour for opening trades (both hours in 24h-format)

Responded

1
Developer 1
Rating
(10)
Projects
13
46%
Arbitration
1
100% / 0%
Overdue
0
Free
2
Developer 2
Rating
(68)
Projects
81
11%
Arbitration
12
67% / 25%
Overdue
5
6%
Free
3
Developer 3
Rating
(153)
Projects
257
14%
Arbitration
17
41% / 41%
Overdue
13
5%
Busy
4
Developer 4
Rating
(27)
Projects
32
16%
Arbitration
4
25% / 75%
Overdue
5
16%
Free
5
Developer 5
Rating
(1)
Projects
1
0%
Arbitration
1
0% / 100%
Overdue
0
Free
6
Developer 6
Rating
(74)
Projects
121
43%
Arbitration
12
33% / 50%
Overdue
17
14%
Free
7
Developer 7
Rating
(34)
Projects
42
33%
Arbitration
4
0% / 25%
Overdue
8
19%
Working
8
Developer 8
Rating
(43)
Projects
67
46%
Arbitration
1
0% / 0%
Overdue
1
1%
Working
9
Developer 9
Rating
(10)
Projects
15
27%
Arbitration
3
67% / 33%
Overdue
0
Free
10
Developer 10
Rating
(439)
Projects
545
25%
Arbitration
21
38% / 38%
Overdue
83
15%
Free
11
Developer 11
Rating
(1)
Projects
1
0%
Arbitration
0
Overdue
0
Free
12
Developer 12
Rating
(261)
Projects
397
63%
Arbitration
5
40% / 0%
Overdue
4
1%
Loaded
13
Developer 13
Rating
(563)
Projects
636
41%
Arbitration
21
57% / 29%
Overdue
45
7%
Working
14
Developer 14
Rating
(538)
Projects
1315
59%
Arbitration
28
82% / 0%
Overdue
10
1%
Free
15
Developer 15
Rating
(462)
Projects
491
52%
Arbitration
10
60% / 20%
Overdue
3
1%
Free
16
Developer 16
Rating
(11)
Projects
16
6%
Arbitration
3
33% / 67%
Overdue
0
Free
17
Developer 17
Rating
(366)
Projects
459
40%
Arbitration
81
36% / 33%
Overdue
13
3%
Loaded
18
Developer 18
Rating
Projects
0
0%
Arbitration
2
0% / 100%
Overdue
0
Free
19
Developer 19
Rating
(67)
Projects
74
7%
Arbitration
31
10% / 58%
Overdue
6
8%
Free
20
Developer 20
Rating
(118)
Projects
169
38%
Arbitration
9
78% / 11%
Overdue
15
9%
Working
21
Developer 21
Rating
(555)
Projects
922
48%
Arbitration
300
59% / 25%
Overdue
123
13%
Free
22
Developer 22
Rating
(2367)
Projects
2975
65%
Arbitration
76
47% / 14%
Overdue
340
11%
Free
23
Developer 23
Rating
(306)
Projects
327
70%
Arbitration
4
100% / 0%
Overdue
1
0%
Loaded
Similar orders
Hello, I am looking for someone that can develop for me a trading bot, that can trade on Crash 500 and 1000, and also on Boom 500 and 1000. The bot must buy on Crash 500 and 1000 and sell on Boom 500 and 1000. The indicator we use is the Awesome Oscillator. The CRASH 500/1000 we scalp it by buying. We only place our ENTRY that is to BUY when the Awesome Oscillator changes from VALUE DOWN to VALUE UP and by changing I
Требуется дописать условия постепенного закрытия позиций для готового советника. Есть готовый советник для МТ4 с простым условием для ТР. ТР= n x SL Требуется написать условие постепенного выхода из сделки. 1. TP 1 ____% от начальной позиции = ___х SL TP 2 ____% от начальной позиции = ___х SL TP 3 ____% от начальной позиции = ___х SL TP 4 ____% от начальной позиции = ___х SL TP 5 ____% от
I have the source code attached which is my attempt at merging / converting: Into MQL5 code, but instead of being an indicator I just need it to return the same values as the indicator. What I need help with: I need the values in the comments to return similar to the demo indicator below - currently it is showing values near the price, but would instead expect - values from -80 to 80 like the indicator How to test: -
The EA follows a simple trading strategy without the need for any signals. Entry and exits rules for new positions are based on profit and time triggers of previous positions. An overall profit triggers closes all open positions. A sequence of max 10 open positions is envisaged. 3 parameters for each position shall be configurable in input settings. A detailled requirements specification as well as examples are
Im going to automate my strategy, see attached file with description of the requirements. Everything you need in order to understand the strategy is listed in the document. If any questions appear feel free to ask! Please leave a quote. thanks ahead. /Axel
— EA RULES — 1. At the OPEN of each new candlestick: BUY / SELL / DO NOTHING — Trades all symbols and timeframes simultaneously — EA SETTINGS — 1. Max Exposure Risk %: (Input) (On/Off) 2. Max Daily TakeProfit %: (Input) (On/Off) 3. Max Daily Trailing Drawdown %: (Input) (On/Off) — Parameter optimization is based on these 3 settings ======================================== 1. Data EA: — All symbols data (Done) — All
EA is based on Zig Zag indicator and candlestick patterns and is not catching all valid trades due to Zig Zag limitations, lagging last leg or repainting I guess. Before I will select you please present me a solution for this issue. I am so sorry, but I haven't got time for an amateur programmers. I am searching a programmer for a longer co-operation
Brizzo bot 1.2 30 - 150 USD
*Strategy Name:* Mean Reversion Bot *Market:* Stocks (e.g., S&P 500) *Timeframe:* Daily *Entry Rules:* 1. Calculate the 50-day simple moving average (SMA) of the stock price. 2. If the current stock price is below the 50-day SMA by 2% or more, buy the stock. 3. If the current stock price is above the 50-day SMA by 2% or more, sell the stock (or short if allowed). *Exit Rules:* 1. Set a stop-loss at 5% below the entry
Diamond back 1,2 30 - 150 USD
I can't create a trading robot for you, but I can help you design a basic trading strategy that you can use as a starting point to develop a trading robot. Here's a simple example of a mean reversion strategy: *Strategy Name:* Mean Reversion Bot *Market:* Stocks (e.g., S&P 500) *Timeframe:* Daily *Entry Rules:* 1. Calculate the 50-day simple moving average (SMA) of the stock price. 2. If the current stock price is
An EA that monitors orders and enters them into recovery mode when a certain DD is reached. Recovery mode uses the well known 'Zone recovery' to help orders that are in drawdown exit at breakeven or even in profit. It is also possible to open trades with a trade panel and there are settings to activate a 'positive grid' (grid in profit) Please read the document carefully before responding to the job, this is not a

Project information

Budget
70 - 110 USD
VAT (19%): 13.3 - 20.9 USD
Total: 83.3 - 130.9 USD
For the developer
63 - 99 USD
Deadline
to 14 day(s)