indicator Help needed for iteration function section!!!!

 
Hey, am making an indicator that counts the total (bid) tick size up (and down for another indicator window) at rate of per n seconds.....in the "indicator iteration function" I couldnt find funtions that work for this formula (I tried "BidPrice - LastBidPrice" for Range function but there are other wrong codings in that section....
Files:
Reason: