Code to store price generated using buy script and use it exit long script


The following is my buy script


I want to store the price generated by this script and use it in exit long script for exiting the position.

Please let me know how write code for that

hElLO tRaDeR,

Tradescript recognizes only candlestick conditions to give you trade alerts for entry and exit.

There is no function in Tradescript language to create an exit alert based on your trade entry price.