Trading on trend line breaks in MT4 and MT5: Expert, Indicator and Script Code

  Рет қаралды 13,474

Orchard Forex

Orchard Forex

Күн бұрын

Пікірлер: 67
@garyhoffmann1615
@garyhoffmann1615 3 жыл бұрын
You are a Champion, exactly what I need for an EA I am working on.
@totati
@totati 3 жыл бұрын
Dear Orchar Forex, thanks for this video too. Only a very small and not too important comment: #property script_show_inputs is already working in mql4 too.
@OrchardForex
@OrchardForex 3 жыл бұрын
Thank you. I hadn't noticed that one.
@gotofree2669
@gotofree2669 2 жыл бұрын
You are amazing that you provide this free content. I WAS WONDERING IF YOU WOULD WRITE AN RSI DIVERGENCE CODE FOR MT4
@oratiletamalah4765
@oratiletamalah4765 Ай бұрын
Thanks for this video Sir, I would like to ask if we wanted to code so that if an X amount of bars failed to cross the trendline how would I be able to implement that? I apologize if my question isn't clear.
@OrchardForex
@OrchardForex Ай бұрын
You would have to loop through that number of bars and compare high/low to the trend value at each bar.
@masoodkhodayi3712
@masoodkhodayi3712 2 жыл бұрын
excellent thanks for sharing
@mql5course938
@mql5course938 3 жыл бұрын
Thanks for this video. How did you load the Trend line ( yellow line ) to visual Tester? When I try to test the indicator, I do not see my Trend line.
@OrchardForex
@OrchardForex 3 жыл бұрын
Draw the trend line first on a template. See kzbin.info/www/bejne/rJeldaxrZ6uNr68
@abcd12346768
@abcd12346768 2 жыл бұрын
Thank you for the great code!! This is exactly the code i needed!!!
@cozzi67
@cozzi67 Жыл бұрын
do u have a copy of the code, I started typing it out and managed to compile the 1st bit ( albeit with many typo's etc) so would be helpful if we could downlaod the code -thanks in advance
@bonginkosibenedict9654
@bonginkosibenedict9654 3 жыл бұрын
Thank you for the Lesson it's very helpful. Can the code be modified so that when the candles comes from above and touches the Trendline a buy order is executed and candles coming from below a sell is executed.
@ahmedsafwat1460
@ahmedsafwat1460 3 жыл бұрын
Thanks a lot for your great work! I tried to do the same code at MT4, Complier yells at me when declaring the function outside using the scope opertor (ENUM_OFX_TREND_BREAK CTrendLevel::GetBreak(int index)) It tells me: "ENUM_OFX_TREND_BREAK, identifier already used" I don't understand why it seems the declaration of the enum above as a first usage and fail to build here, any idea?
@aliabdulla3906
@aliabdulla3906 Жыл бұрын
Hi Orchard thanks for your tutorial it is great work I write mqh file in mt4 but it gives me 13 errors, is there any additional file I need to use. thanks again
@OrchardForex
@OrchardForex Жыл бұрын
You need the expert mq4 file and the trendlevel mqh file. If you take time to read the error messages they will tell you if you are missing any files.
@oratiletamalah4765
@oratiletamalah4765 Жыл бұрын
Thanks for this amazing video! I want to be able to draw more than one Trend Line and have the Expert check each trend line. What should I do?
@OrchardForex
@OrchardForex Жыл бұрын
Any line you draw on the chart is an object and has a name, you just have to search the objects.
@oratiletamalah4765
@oratiletamalah4765 Жыл бұрын
@@OrchardForex Thank you
@oratiletamalah4765
@oratiletamalah4765 Жыл бұрын
In terms of the indicator since it doesn't use any buffers, how would one use it with the iCustom function?
@OrchardForex
@OrchardForex Жыл бұрын
@@oratiletamalah4765 see 2:17
@oratiletamalah4765
@oratiletamalah4765 Жыл бұрын
@@OrchardForex see when using the iCustom function when interpreting the buffer number for the indicator? Instead of using an actual number for the buffer, I used the statement 'true'. Because the indicator has no buffers. Did I do it right? I got no errors or warnings, and it's working as it should.
@jglazebrook8930
@jglazebrook8930 2 жыл бұрын
Thank you again!!! Great coding.... Is there a way to get the expert to rename the trendline rather than stop trading? Thank you again.
@OrchardForex
@OrchardForex 2 жыл бұрын
Try using ObjectSetString with argument OBJPROP_NAME
@jglazebrook8930
@jglazebrook8930 2 жыл бұрын
@@OrchardForex Thank you. I will try this, this coming week end....
@jglazebrook8930
@jglazebrook8930 2 жыл бұрын
​@@OrchardForex Thank you. ObjectName has individuality, Is there a way to retrieve objects going by only a part of the ObjectName. For example, indicators may draw objects with ObjectName Low1 for the 1st object, Low2 for the 2nd object and Low3 for the 3rd etc.... Is there a way of identifying only the "Low" part of the ObjectName? Thank you. Or maybe a way of using ObjectDescription. Because that can be repeated.
@OrchardForex
@OrchardForex 2 жыл бұрын
@@jglazebrook8930 Just use substring compare
@2907866
@2907866 2 жыл бұрын
Hi, thanks for sharing this! However, the trendline that I draw is missing when I run the strategy tester. Do you know any possible reason for this?
@OrchardForex
@OrchardForex 2 жыл бұрын
Yes. How are you drawing the trend line on the strategy tester?
@2907866
@2907866 2 жыл бұрын
@@OrchardForex I draw the trendline as usual on my chart and use its name in the input. I also tried drawing it on the chart which is opened by clicking "Open Chart" on the strategy tester. A new chart is also opened every time I start running the test and there is no trendline on the chart that is opened when I run it in visual mode.
@krontexpit
@krontexpit 3 жыл бұрын
Hi Orchard Forex, I greatly appreciate your videos. I have switched from TradingView to MT4. I have noticed there is a discrepancy between OHLC values and Volume when comparing both platforms. I understand that the tick data comes from different sources. Is there any way to change the live feed source in MT4? Maybe by creating an offline chart with a custom source?
@OrchardForex
@OrchardForex 3 жыл бұрын
If you can find another source there is no reason why you can't feed that into a history file and use the history file as an offline but you will still have to trade at the broker's price so I don't see the point.
@krontexpit
@krontexpit 3 жыл бұрын
Orchard Forex I see what you are saying, thank you
@shahinsinv
@shahinsinv 3 жыл бұрын
Sir, Thank's for this Tutorial, I want to trade Higher TrendLine and Lower Trendline. Here we can see that when Price crosses TrendLine Prices is already High, can we make it when Price Breakup LowerTrendline we can Buy with Prev candle Low + some Pips and will be ready for sell at near Higher Trendline or cross. if You can Please Make One video Tutorial for that. And Further Please Put the Link Of this Video for Download this Source Code File. Thanks
@OrchardForex
@OrchardForex 3 жыл бұрын
I only ran the demonstration for breaking above but the code already has conditions for breaking below, The code triggers any time the price moves across the trend line in either direction. So far I haven't made this code available for download.
@jafxtradinginstitute6395
@jafxtradinginstitute6395 3 жыл бұрын
When trading trendline you trade after the retest. Enter at a close of the bullish candle that cancel out the sell.. or a break of the pullback structure.
@75hilmar
@75hilmar 3 жыл бұрын
Thanks a ton!
@productvisibilitytvshoppin1107
@productvisibilitytvshoppin1107 2 жыл бұрын
Fantastic!
@OrchardForex
@OrchardForex 2 жыл бұрын
Glad you like it!
@TheJoshuamcgowan
@TheJoshuamcgowan 3 жыл бұрын
one of my setups I trade is a double bottom on the other side of a trend line break. curious if you already have a tutorial on that which I can combine with this to practice a bit more mql coding? thx in advance and these videos are really good value. instant subscribe haha
@TheJoshuamcgowan
@TheJoshuamcgowan 3 жыл бұрын
by double bottom I mean a W in price making higher lows for example
@OrchardForex
@OrchardForex 3 жыл бұрын
No I don't have anything about double bottoms or double tops. There are several videos on detecting peaks that might help, check the channel link to see everything we have.
@TheJoshuamcgowan
@TheJoshuamcgowan 3 жыл бұрын
Will do thank you
@joaquimcom
@joaquimcom Жыл бұрын
Grat video, many thanks for your work. I have a problem and maybe you can help me. I tray in part two simulate with dre previous draw line bur diring 3 days I have not been able to see the line durin simulation. What I'm doing wrong? When begin simulation it opens a new window but the line is not there. If need I can send you a video. Many thanks !!
@OrchardForex
@OrchardForex Жыл бұрын
SR lines depend on finding enough zig zag points at the same level. If you are using strategy tester there may not be any older or enough zig zag points. Add the zig zag indicator and see how many points have been drawn
@joaquimcom
@joaquimcom Жыл бұрын
Many thanks for your feedback. !!
@BuKhalid81
@BuKhalid81 2 жыл бұрын
Hello, Thank you for these great tutorials and all other ones also, have helped me a lot in my trading, especially this one, I use it as an alert when price breakthrough support/resistance/trendlines, so as a beginner in programming, I've tried to tweak it to alert on multiple lines within the same chart, but failed miserably. Can you please guide me? I'm currently using it in multiple charts to alert on multiple lines.
@BuKhalid81
@BuKhalid81 2 жыл бұрын
I found a way, maybe not practical but worked for me, I duplicated the function, and duplicated a separte class file
@solaris4015
@solaris4015 2 жыл бұрын
What should I change, if I want to this exact ea, but to buy exactly when it crosses the line, without the confirmation ?
@OrchardForex
@OrchardForex 2 жыл бұрын
Look for the first tick with price over the line.
@solaris4015
@solaris4015 2 жыл бұрын
@@OrchardForex Thank you very much !
@RealDealMcCoy11
@RealDealMcCoy11 3 жыл бұрын
Is there a way to get the max level of a sub window indicator so I can use that number within an indicator to generate signals based on the sub window levels?
@samuelagina1
@samuelagina1 3 жыл бұрын
Good morning sir , like your works Pls can you code me an Ea? I want to code my trading system into an Ea . Can you please?
@benbua5521
@benbua5521 2 жыл бұрын
Hey your link to the trendline break indicator for mt5 brings me to ic markets. .. can you Post the mt5 trendline break indicator as Dropbox or Google drive link. Awesome content Would be nice Best regards ben
@OrchardForex
@OrchardForex 2 жыл бұрын
There is no link to download the code for this.
@jafxtradinginstitute6395
@jafxtradinginstitute6395 3 жыл бұрын
1:40 min there about that huge candle at the trendline. Divergence occurs there ?
@OrchardForex
@OrchardForex 3 жыл бұрын
It's only a 1 hour chart and that would have been a weekend price gap.
@AplainEast
@AplainEast 3 жыл бұрын
Greetings Sir (would you mind creating another tutorial ,explaining how to draw Trendline per every 10-100 bars_)
@OrchardForex
@OrchardForex 3 жыл бұрын
Do you mean a line to find the trend over a specified number of bars?
@AplainEast
@AplainEast 3 жыл бұрын
@@OrchardForex yes sir.
@dawoodhassankhan2326
@dawoodhassankhan2326 3 жыл бұрын
Hey man Nice video ...i have a question ...How we can open Multiple Real Account with Different broker and Also with the same Broker ... And All Trade Just with one click without CopyTrading ... One master Acc Open trade And That trade also open with Different Account With one click ... Please
@OrchardForex
@OrchardForex 3 жыл бұрын
You can add as many accounts from as many brokers as you like to a single MT4 or MT5 (but I don't recommend it) but you can only have one open at a time, Copy trading would be the best option to trade multiple accounts at one time.
@onenationoneeducation3344
@onenationoneeducation3344 3 жыл бұрын
where we get this script
@abadyhabra7024
@abadyhabra7024 3 жыл бұрын
you got it? because I need it too
@tomrichmond683
@tomrichmond683 Жыл бұрын
Thanks for these videos - amazing work! When I compile the indicator, I get no errors or warnings, but then try to run it in the Strategy Tester as you do, but it fails due to "Invalid pointer access" and points to the line ENUM_OFX_TREND_BREAK brk = TrendLevel.GetBreak(1); //Did the closed bar break I can't for the life of me spot where I've gone wrong - any help would be appreciated!
@OrchardForex
@OrchardForex Жыл бұрын
Sounds like TrendLevel has not been created as an object yet.
@tomrichmond683
@tomrichmond683 Жыл бұрын
@@OrchardForex Thank you!
typedef - Function Pointers in MQL4
21:40
Orchard Forex
Рет қаралды 1,3 М.
Beginners guide: Write your own RSI Expert Advisor for MT4
51:24
Orchard Forex
Рет қаралды 24 М.
啊?就这么水灵灵的穿上了?
00:18
一航1
Рет қаралды 81 МЛН
黑的奸计得逞 #古风
00:24
Black and white double fury
Рет қаралды 26 МЛН
Osman Kalyoncu Sonu Üzücü Saddest Videos Dream Engine 262 #shorts
00:20
5 Minute Scalping robot for MT4 and MT5
31:28
Orchard Forex
Рет қаралды 15 М.
I Made $4,000 Using This Scalping Strategy
5:28
The Moving Average
Рет қаралды 4,7 М.
Create a Floating Support and Resistance Indicator from Any Channel
28:26
Find Upper and Lower Trend Lines with MQL
33:25
Orchard Forex
Рет қаралды 12 М.
The Safe Way to Call Custom Indicators in MQL4
15:15
Orchard Forex
Рет қаралды 9 М.
Jim Cramer takes a closer look at today's sell-off
10:38
CNBC Television
Рет қаралды 27 М.
MQL By Request - #1 - EA Framework part 1
30:19
Orchard Forex
Рет қаралды 12 М.
Code an Inside Bar Buy and Sell Indicator
25:28
Orchard Forex
Рет қаралды 7 М.
Use Common Classes to Write MQL4 and MQL5 Experts
48:04
Orchard Forex
Рет қаралды 10 М.
啊?就这么水灵灵的穿上了?
00:18
一航1
Рет қаралды 81 МЛН