Need help to create AFL stretegy code

Dear members,
Please help to create my trading stretegy based AFL.
I need to have a popout window AFL
on previous candle (close) Buy/ Sell based condition
previously closed candle Up/Down arrow based condition. The popout window must appear only once in entire buy cycle or Sell cycle.

any one condition will be fine.
if Buy = xyz condition is met

popout window ( for buy) (non repeatative) appears

if Sell = xyz condition is met

popout window (for sell) (non repeatative) appears.

Thx in advance for your kind help.

Similar threads

Zerodha – Open Paperless Account

Open online account with Zerodha. Free delivery trading and Max Rs 20 for Intraday, F&O, Currency and Commodity Trading. Intraday High leverage with MIS, CO and BO.

Are you a day trader?