Calc Invoices to Pay?

Stanley Barnett stanley at stanlyn.com
Thu Mar 6 18:36:37 PST 2008


> The reason you spent a long time searching for the right combination
and not finding 
> it is because there is no combination that matches those amounts.

The little routing I'm asking for should be able to tell me that in a
second or two, therefore saving me the wasted time I spent looking.

BTW, I talked to the customer today and learned that he had split some
invoices across the 2 payments (checks).  That's perfectly fine, but if
I had known that from the beginning I would not have spent the time on
it, instead I would have called him for the details.  The code I'm
looking for should have quickly figured it out as both you and I did and
issue a message box saying no combination could be found. 

How long did you spend searching for a combination?  Did you test all
possible combinations?  And, how did you test?

Thanks,
Stanley Barnett  -  stanley at stanlyn.com
Stan-Lyn & Associates, Inc.  -  http://www.StanLyn.com
Office: (859) 402-8165  -  Cell: (606) 568-5412



-----Original Message-----
From: Kenneth Brody [mailto:kenbrody at bestweb.net] 
Sent: Wednesday, March 05, 2008 11:33 PM
To: Stanley Barnett
Cc: filepro-list at lists.celestial.com
Subject: RE: Calc Invoices to Pay?

Quoting Stanley Barnett (Wed, 5 Mar 2008 20:24:20 -0500):

>
>> Just curious -- how many invoices were there?
>> Could you post a list of the invoice amounts, and the check amount, 
>> as
> a set of test
>> values for anyone wanting to try it out?
>
> Hi Ken,
>
> Here are the details of the last time I could not resolve...
>
> 20070101529 01/03/2007 POST      375.00      375.00
> 20070101523 01/18/2007 POST       96.88       96.88
> 20070101534 01/20/2007 POST      150.00      150.00
> 20070301533 03/13/2007 POST     1563.34     1563.34
> 20070701489 07/23/2007 POST      452.48      452.48
> 20070901528 09/04/2007 POST      764.46      764.46
> 20071001527 10/20/2007 POST      162.50      162.50
> 20071001526 10/22/2007 POST      380.00      380.00
> 20071101525 11/10/2007 POST      594.93      594.93
> 20071201522 12/13/2007 POST      655.00      655.00
> 20080101524 01/18/2008 POST       96.88       96.88
> 11 invoices,
>
> I received 2 checks, one for 998.97 and one for 4292.00

>> The reason you spent a long time searching for the right combination
and not finding >> it is because there is no combination that matches
those amounts.

For $4292.00, you have:

   375.00 1563.34 452.48 764.46 162.50 380.00 594.93 = 4292.71
   375.00 96.88 150.00 1563.34 764.46 594.93 655.00 96.88 = 4296.49

For $998.97, you have:

   452.48 162.50 380.00 = 994.98
   96.88 150.00 655.00 96.88 = 998.76

For a combined sum of $5290.97, you have:

   375.00 96.88 150.00 1563.34 452.48 764.46 162.50 380.00 594.93 655.00
   96.88 = 5291.47

-- 
KenBrody at BestWeb dot net        spamtrap:
<g8ymh8uf001 at sneakemail.com>
http://www.hvcomputer.com
http://www.fileProPlus.com


More information about the Filepro-list mailing list