Requests & Ideas (MQL5 only!) - page 28

 
ekren Clausewitz :

Hello Vladimir;


Your trailing profit works well. Thanks.


Thanks for the tip.

And what program is it about? :)

 
Vladimir Karputov:

Thanks for the tip.

And what program is it about? :)

https://www.mql5.com/en/code/18709  Minimum profit with percent of profit.
Trailing_Profit
Trailing_Profit
  • votes: 15
  • 2017.08.10
  • Vladimir Karputov
  • www.mql5.com
Closing all open positions with the specified profit percent.
 

A script (not an advisor) setting pending orders.

The script exposes the grid of pending orders ...

 

Another idea:

Indicators + Alerts.

Add alerts for standard indicators. For example, for MACD: notification "Zero-line intersection" and others. For RSI: "The indicator is higher (or lower) than a certain level." ...
 
Vladimir Karputov:

A script (not an advisor) setting pending orders.

The script exposes the grid of pending orders ...


According to the plan, the script should place pending orders up and down from the price.

The more I write, the more doubts: "Maybe you need two separate scripts? One for placing pending orders UP from the current price, and the second for placing pending orders DOWN from the current price?".

 
Vladimir Karputov:

According to the plan, the script should place pending orders up and down from the price.

The more I write, the more doubts: "Maybe you need two separate scripts? One for placing pending orders UP from the current price, and the second for placing pending orders DOWN from the current price?".


I think - it should be one script because it is related to the distance from the pending order price to the market price (to be same in 'buy stop order price/market price distance' and 'sell stop order price/market price distance').
This script may be usefull to trade the news events for example.

Example:

OrdersNumber   = 2        // Number of pending orders for each side
PendingGaps    = 15       // Gap for pending orders from the current price in pips
StepOrders     = 10       // Step between orders in pips
Initial Stop   = 100     // Initial stop in pips
TakeProfit     = 50      // Take profit in pips
Basic Principles - Trading Operations - MetaTrader 5 Help
Basic Principles - Trading Operations - MetaTrader 5 Help
  • www.metatrader5.com
Before you proceed to study the trade functions of the platform, you must have a clear understanding of the basic terms: order, deal and position...
 
Vladimir Karputov:

A script (not an advisor) setting pending orders.

The script exposes the grid of pending orders ...


Setting pending orders as quickly as possible: the mode CTrade::SetAsyncMode.

Pending orders UP


Pending orders DOWN

 
Vladimir Karputov:

A script (not an advisor) setting pending orders.

The script exposes the grid of pending orders ...


Due to the asynchronous mode, the scripts Pending orders UP  and Pending orders DOWN display five orders (the time from the sending of the first trade order to the confirmation of the last pending order placement) for the time from 70 to 80 milliseconds!

 
Vladimir Karputov :

Another idea:

Indicators + Alerts.

Add alerts for standard indicators. For example, for MACD: notification "Zero-line intersection" and others. For RSI: "The indicator is higher (or lower) than a certain level." ...


There are many indicators and each has its own signals. But at the same time processing of alerts and sending alerts is a repeating algorithm, I think it will be better if you split the functional:

  • A external class, while I'll call it "Alerts", which calculates the signals and is engaged in sending alerts.
  • And in the indicators there will be a block that searches for signals and transmits the signal name to an object of the "Alerts" class .

Indicators + Alerts

 

Hi Vladimir;

I didn't understand your last EA which is using M!,M5 and H1 i-Regr indicator. Could you visualize buy/sell points?


Thanks.

Reason: