EasyLanguage Clinic

Discussion in 'Trading Software' started by tommo, Jan 19, 2009.

  1. tommo


    Hi all,

    I am new to Tradestation and am a bit stuck with coding a stop. I think the code should be pretty simple but havent been able to get anyone to help me thus far.

    Basically, i know how to code a stop at the high of one bar ago, but this always turns in to a trailing stop. What i want to do is have a stop at the high of the bar previous to the bar i sold, or EntryBar[1] if you like and remain there (no trail) throughout the trade.

    Hopefully my attempt at drawing a trade example (see attachment) explains it better.

    I assume it involves a "setstoploss" function of some sort, but im not sure how. (only had TS for a week)

    if someone could write the Easylanguage code for this it would be a great help

    <img src=http://www.elitetrader.com/vb/attachment.php?s=&postid=2265614>