thanks for the reply.
I need to show the outstanding amount ant the days.
Your application shows the normal days.
its not checking whether its having outstanding amount.
to check we have to consider the ID field for amount.
to calculate the days we have to consider the ID and starting Voucher no and Voucher date.
thanks for ur reply.
we have to consider the first invoice date.
For ex, Category A and ID 2 for Jan
the outsatnding amount is 500-250=250
the outstanding days is 31/01/2012-12/20/2011=42
dont consider the partial payments..
they paid 250 on 01/20/2012 but the actual amt is 500 raised on 12/20/2011
we have to consider the 12/20/2011.
thanks in advance