Since you have done it in PBP and if you don't mind, could you post the code you tested please?
Maybe there is a way to overcome the Long need using functions of 32 bit like DIV32?
Ioannis
P.S. Test it in Excel and I think there is a mistake on the B3 function. My output result on B13 is always equal to B11.
Bookmarks