Hi scourt2000 and Allan Because I am new to coding and not confident of my code I have not posted a response. But, as no AFL breakeven stop has been posted, here is the code I use, which was developed with the help of Graham, which you could check for correctness.
//=====B.E. STP STRTS =============================================== BuyPrice= ValueWhen( Buy, BuyPrice, 1 ); SellPrice = BuyPrice; //USE ValueWhen OR ATR KEEPS CHANGING FOR EACH SUCCESSIV BAR Stp_SetThreshold = ValueWhen( Buy, BuyPrice + (1 * ATR(14)), 1 ); Stp_MvToBrkEvn = ValueWhen ( High > Stp_SetThold, 1, 1 ); Sell = Sell OR Stp_MvToBrkEvn = 1 AND Low < BuyPrice; //=====B.E. STP ENDS =============================================== ApplyStop(stopTypeProfit, stopModePoint, 1 * ATR(14), ExitAtStop = 1, True); //Gain Buy = ExRem(Buy,Sell); Sell = ExRem(Sell,Buy); britefire ------------------------ Yahoo! Groups Sponsor --------------------~--> Great things are happening at Yahoo! Groups. See the new email design. http://us.click.yahoo.com/TISQkA/hOaOAA/yQLSAA/GHeqlB/TM --------------------------------------------------------------------~-> Please note that this group is for discussion between users only. To get support from AmiBroker please send an e-mail directly to SUPPORT {at} amibroker.com For other support material please check also: http://www.amibroker.com/support.html Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/amibroker/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/