Is it possible to have indicator that activates SL and TP?

 

I am currently studying MT4 coding. Just curious if it is even possible to have SL and TP function in the indicator? 

 
gihyunn89711:

I am currently studying MT4 coding. Just curious if it is even possible to have SL and TP function in the indicator? 

No, trade functions can only be managed by an EA. An indicator may be able to pass such info to an EA, but the EA must control the actual SL/TP
 
You can use info from indicator inside you ea to define sl and tp