I see that you are new, so this solution with a loop and a variable might look like black magic, but here it is anyways lol:
https://fxdreema.com/shared/ZKvsHLgYc

Posts made by roar
-
RE: Hi guys, how do I enable two non-concurrent conditions?posted in Questions & Answers
-
RE: How to achieve "wait" in seconds?posted in Questions & Answers
I never work with time, so this is just a guess, by try this:
https://fxdreema.com/shared/eglnRYR2cinfo:
https://www.mql5.com/en/forum/162999
https://www.mql5.com/en/docs/dateandtime/timecurrent -
RE: how to set distance pipposted in Questions & Answers
Easiest way is to use Envelopes indicator.
-
RE: Creating conditions based on indicators using a previous indicators dataposted in Questions & Answers
@xlabcapital You cant do that, but ATR 1 and 20 is pretty much the same

-
RE: 3rd candle of the dayposted in Questions & Answers
@chicrala said in 3rd candle of the day:
Hi, how can I identify that "this is the 3rd candle of the day" to start an action (buy for example)?
Create a variable that counts candles, reset it once each day, then check if variable == 3.
-
RE: i am new ? i want put password to my eaposted in Questions & Answers
@ranjayforex I would create a list of hashes, like 100 different hashes, and those would act as "licenses" for the EA. Before the EA starts (OnInit) put a loop that compares the user-input hash to the listed hashes, and if no match is found -> terminate
This would still allow users to share their own "passwords" to other users, but anyway I would say MQL is not the best for cryptographic purposes....
-
RE: Scam alert...!!!posted in General Discussions
I don't really want to get involved in this dispute, but in general you should avoid these kind of risk graphs - bad trades are solved by increasing the lot size:

-
RE: Trailing stop based on ATRposted in Questions & Answers
@sammylegacy1 Hi!
I dont know about the custom indicator, but here's how to do trailing stop in fxdreema.
https://fxdreema.com/shared/DgGkyNU2d

-
RE: A line toolposted in Tutorials by Users
I continued this project by extrapolating the lines, allowing to compare current price to the extrapolated line.
Why I made it so unneccessarily complex is, this way I never have to read any values from objects, everything is done mathematically. Reading values from objects is buggy as ****. Also, thinking ahead, it's easier to implement into multi-currency systems...
-
A line toolposted in Tutorials by Users
I made a fun little tool that creates high-low lines based on RSI, and decided to share it here in case anyone finds use for it.
I will not bother explaining this in detail, feeling lazy lol
https://fxdreema.com/shared/n4LXpQO1b

-
RE: How to set group number for a group of block ?posted in Questions & Answers
@migen I'd say using a variable in the group number is the best option, you will have to touch every block, though.
Also make sure that your system is not unnecessarily big, usually you can reuse the same blocks with a loop...
-
RE: Simple moving average cross EA PLEASE HELP MEposted in Questions & Answers
Put "once per bar" on top of your project, and also use candle ID 1 in the block settings. These are the basic tricks for every problem lol
-
RE: Problem selecting variablesposted in Bug Reports
This mysterious bug has happened to me too. Try writing the variable into the field instead of inserting it with right-click.
-
RE: how to achieve this?posted in Questions & Answers
@l-andorrà @Zackry Hi!
Its just trickery with the candle ID. Here's an example that plots the ma crossing points, hope you get the idea:
https://fxdreema.com/shared/YndXsmKM -
RE: MA 2 Crossoverposted in Questions & Answers
@rosliomar the fxdreema EAs never attach the indicators, they only work on the background. If you want to see the lines, you will have to manually add them
-
RE: Another question for real programmers.posted in Questions & Answers
@l-andorrà Just use bool type in the constant
https://docs.mql4.com/basis/types/integer/boolconst


-
RE: How to modify one order in a block if another one hit target?posted in Questions & Answers
@faiz43 You can better control those mechanics from the On Trade tab, using a suitable activation:

-
RE: How to modify one order in a block if another one hit target?posted in Questions & Answers
@faiz43 "Check trade count == 1" and then "Once per trades" and then this "modify stops"
-
RE: Moving average levelsposted in Questions & Answers
@fabiobioware Envelopes. Use envelopes indicator, its the same thing but much simplier.
-
RE: Close trade only if condition is recurringposted in Questions & Answers
@zaccroft does the block "no trade" solve your problem?
Or if its a above/below condition, switch to "cross above" / "cross below"
