You are in the good direction, yes. Just add a condition block before the buy pending block comparing the values of that variable and the input parameter. The variables' value needs to be below or equal to the input parameter's.
Posts made by l'andorrà
-
RE: I am new to this platform and trying to build an EAposted in General Discussions
-
RE: EA BASED ON ELLIOT WAVESposted in General Discussions
If any of the indicator is repainting, I simply wouldn't use it. No stable bot can be built based on a repainting indicator. Can you find a non repainting indicator instead?
-
RE: Heiken Ashi auto buy and sell question.posted in Questions & Answers
Can you please share the link to your project?
-
RE: EA not functioning effectivelyposted in Questions & Answers
The problem is you're requesting the crossing to be confirmed at the opening of candle ID 0. That means the crossing is not confirmed at that moment. You need to specify candle ID on blocks 3 and 7 to avoid that.
-
RE: Candle IDposted in Questions & Answers
Do you mean consecutive candles? That is not necessarily a swing high.
-
RE: varias operacionesposted in Questions & Answers
@juandavid713 Con este bloque le estás diciendo al bot que compruebe si no hay ninguna otra operación abierta 20 pips por encima y por debajo del precio actual:

-
RE: not to trade after profitposted in Questions & Answers
But what if trades 1 and/or 2 are in profit as trade 3? And what if the situation changes through the candle's evolution in time?
-
RE: tp risk rewardposted in Questions & Answers
@navidt You need to remove all SL data from both buy/sell pending orders and then add this:
-
RE: My project says Compilation errorposted in Questions & Answers
That trailing stop bloc needs to be removed from its current position for sure. On the other hand, I don't fully understand how the strategy is supposed to work. Could you please elaborate?
-
RE: Open trade at the opening of the next candlestickposted in Questions & Answers
I'm not sure I fully get the closing part. Do you mean the trade is to be closed at the end of the same candle the trades was open no matter what?
-
RE: GAP EA F40 sell order stopposted in Bug Reports
Is this the whole structure or just part of it?
-
RE: Resetting custom lot levels after trade is closed.posted in Questions & Answers
Thanks for sharing.
-
RE: Hedging problemposted in Questions & Answers
Ok. Now we need to define the hedging conditions. How many open trades is the bot supposed to open at any time? Infinite?
-
RE: Max number of daily tradesposted in Questions & Answers
Did you try jstap's suggestion? That would work.
-
RE: Please, need help to solve my 3 PROBLEMS.posted in Questions & Answers
Did you check if all those indicators repaint? Because if ANY of them does, the bot is doomed.
-
RE: Can#t trace the custom indicatorposted in Questions & Answers
That decimal poaitions are not relevant for the internal calculations. Do you want to remove them for visual reasons only?
-
RE: Reporting the bug related to capital management "Risk % of Balance (Volume size depending on Stop-Loss)" in the MQL5 language.posted in Bug Reports
Are you sure you are using the correct pip size rules? XAUUSD is not a standard forex symbol.
