Code for ADX

the below code is generating an error message wherein I want to code for buy: when the current adx level is greater then the previous adx level : :ADX(CLOSE,45)>REF(ADX(CLOSE,45),1)

Could you please correct it suitably…

Shailender,

RS2548

As per above

Buy

 ADX(14) > REF(ADX(14),1)