ORB code for pi not working

a couple of codes I entered in backtest showing an error message in ORB strategy so if possible pls provide a code that works…

regards
JISHO JOY