The contents of the Adjust field where you now have "+1pips" goes to the output MQL4 code almost directly. This is also true for all input fields. You can write MQL4 functions everywhere, not only numbers
Posts made by fxDreema
-
RE: Trailing stops EAposted in Questions & Answers
-
RE: i want protect my code in EA.ex4 how i do that ?posted in Questions & Answers
I don't know, ask Google

-
RE: close tradeposted in Questions & Answers
In your project all of these blocks with red borders are disabled, they can't run - http://prntscr.com/bpalq2
-
RE: Open orders based on the indicator is possible?posted in Questions & Answers
Click the "Update" button. If this doesn't work... add second indicator and then in the block choose the one you want. I think the problem is only visual, it appears that some indicator is selected, but it's not. I think that "Update" will help.
-
RE: Close trade using MA crossoverposted in Questions & Answers
No, there is no such code. What works on the tester should wotk live. But it depends, because the tester is a little bit different. Do you have error messages?
-
RE: and/orposted in Questions & Answers
This example shows If-then-else logic.
- If Condition 1 is true, run Buy now, otherwise...
- If Condition 2 is true, run Buy now, otherwise...
- If Condition 3 is true, run Buy now, otherwise...
If Condition 1 is true, Condition 2 and 3 will not run, they are not needed anyway. This is why this method is good.
-
RE: if i work EA on my account and i turn off my PC?posted in Questions & Answers
Depends. For the most part, you need the EA to work. Only if you have trades with Stop-Loss and/or Take-Profit, they are triggered on the server. Also, pending orders are triggered on the server. Everything else is done by the EA.
-
RE: Displaying the market price where multiple trades will make a particular gross profitposted in Questions & Answers
If you can calculate the value, you can draw it on the chart as a horizontal line or something like this. There are not many blocks who can draw anything, because this is an EA bulder, not Custom indicators builder
-
RE: working with (Round Number Detector)posted in Questions & Answers
Fixed (I think). The problem was in some code optimizations that happen when generating the output code
-
RE: Please help to close positions after reaching profit / lossposted in Questions & Answers
What symbol are you working on? I can see in one of your projects that you have lot sizes like 1. This is huge lot size for symbols like EURUSD. The result I got is that my positions are closed after less than 1 minute.
For those "Draw..." blocks, note that you have set them in a way to make brand new object every time they run. As a result, tousands of objects are created and the backtest runs so slow. Look at the first two options in these blocks. Try with No - Yes instead of No - No.
-
RE: Bug? Draw Line Block using time component for the priceposted in Bug Reports
I made some changes. It turned out to be tricky. I used one native function StringToTime() and I expected that it works with the server time, but no, it works with the local time. So I created another function that hopefully will work better, but who knows.
Also, the native GMT functions are also linked with the local time. -
RE: I need help two custom indicatorsposted in General Discussions
I can see you have this - http://prntscr.com/boumyl
No, "Indicator appear" blocks are not connected as an AND logic, they are connected as OR logic, which means that only one of them needs to be true in order to run the following block. If you want blocks 1 and block 2 to be true before running block 3, then connect them like this 1 -> 2 -> 3, one after another.But "Indicator appear" is not suitable for AND logic. This block passes rarely, when it detects that the value of the indicator turns from EMPTY_VALUE or 0 into something else. And after that the blocks does not pass again until the next time when this event happens. So, these blocks are detecting an event, not a condition. These blocks are different from "Indicator is visible".
It's just almost impossible to have 2 indicators becoming visible on the exactly the same tick. But one can be visible and you can just check whether it's visible, and then you can detect the time at which the other turns from invisible to visible (the event). As you can see, there are some things to be considered

-
RE: Profit drop at end of strategy testingposted in General Discussions
I don't know what is going on over there. These dates mean nothing to me. I don't know you From-To backtest period, it could be anything. Give me more information...
-
RE: Close trade using MA crossoverposted in Questions & Answers
I have no idea what you are missing. I need more details of the problem. There are many, many reasons for something to not work. I can't say what is going on exactly and where is the problem all the time.
-
RE: working with (Round Number Detector)posted in Questions & Answers
keydcuk, give me simple example that contains 2 or 3 blocks and tell me what is your expectation from it. I will check it and I will see what is the problem - this is the idea. Because when I see that someone says something like "doesn't work", I read it like "ak#ka#%khsga2171". It means nothing to me, exactly nothing.
Yes, I tried the block and it worked for me, but I always forget the details in this particular blocks, so I need more information of it's problems.
-
RE: Trailing stops EAposted in Questions & Answers
As MQL4 code this is the spread of the current symbol: ```
MarketInfo(Symbol(), MODE_ASK) - MarketInfo(Symbol(), MODE_BID)Otherwise you can get it's value and put it into a Variable with "Modify Variables" block. -
RE: Please help to close positions after reaching profit / lossposted in Questions & Answers
No, this block works with the closed positions. "Check profit (unrealised)" is the one who works only with open positions.
From this example https://fxdreema.com/shared/JvbQZ9Y5e I got this result http://prntscr.com/boud15. The EA was automatically terminated when the profit reached 20 dollars for the day.When I'm showing examples, I'm showing something that can be seen with the eyes. In this case, the values, as they are. I don't want to make EAs by request, I want to show people how things work. That's why I prefer to show something that exaplains how something works, not exactly the thing that the person is asking for. I want people to know and understand what is going on in these blocks.
-
RE: Open orders based on the indicator is possible?posted in Questions & Answers
What is the problem exactly?
-
RE: Unconventional Grid (Hedge or Trades Nearby)posted in Questions & Answers
With "For each..." blocks you can select any trade or order. Working with these blocks is something that most people don't easily understand, so here are my examples for them - https://fxdreema.com/examples/#Loop-(For-each...) Look at the options on the bottom of "For each..." blocks. If "Not more than N...." is 1, then only the latest one is selected.