I'm converting byte size to cents. 1MB should equal about 1 cent. I want to set a variable to the nearest tenth of a dollar below its current value. If the original number is 682, I want the reslutant number to be 680. If the number is 689, I want it to be 680, not 690.
Accordingly, if the number is 10263 or 10268, I want it to be 10260.
I tried rounding the number (round) but this doesn't quite work, goes to the nearest number, above or below. I always want below.
Cost is derived from the total file byte size and will be converted to a dollar format so that 680 will be $6.80. I don't want the customer to be overcharged, even if it's such a small fraction. And I don't much care for cent amounts that are too diffucult to add for the customer. Tenths of a dollor works for me. That's what I want.
<CFSET cost = NumberFormat(byte_count/1024/1024/100, "9.99")>