0% found this document useful (0 votes)
75 views12 pages

01.07 Trendline Breakout Automated Entry

Trendline Breakout Automated Entry

Uploaded by

Enrique Blanco
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
75 views12 pages

01.07 Trendline Breakout Automated Entry

Trendline Breakout Automated Entry

Uploaded by

Enrique Blanco
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 12

In this tutorial, we're going to create a very useful Expert Advisor.

It will buy or sell when the price breaks through a


trendline that is drawn in the chart.
 

 
Add condition: Price, crosses above, Upper Trendline.
 

 
Set Stop Loss...
 
 
...it will be added to Inputs.
 

 
 

 
 
Set Take Profit the same way.
 

 
 

 
And create the opposite conditions for sell order.
 
 
When the Price crosses below the Lower Trendline, a sell order will be opened.
We have to limit the number of open trades to 1 to prevent multiple orders when the price is oscillating around the
trendline.
 

 
The Money Management is Fixed.
 
 
We can set up audible alerts for each order.
 

 
Here we see we have created two inputs – the Stop Loss and Take Profit:
 
 
And we will also add the Trade Size, so we have three inputs altogether.
 
Copy the source and compile it.
 

 
 

 
Let's try it. Draw two trendlines or horizontal lines in the chart forming a triangle pattern.
 
 
Attach the Expert Advisor to the chart.
 

 
 

 
As soon as the price breaks through one of the trendlines, the order is executed.
 

You might also like