Page 1 of 1

Reopen A subject

Posted: Tue Dec 10, 2019 2:03 pm
by omni
Roger,

I'm not sure you remember this but we have a user that prints all invoices to a pdf using win2pdf and the dollar amount is wrong. I know, you said it was our code, but it is not. We have hundreds of users doing this and it just started happening randomly at this site and it prints the wrong number in one location.
We are recording what is sent to the printer in txt file and confirming it matches the invoice total and the billing detail
All 3 that he found recently and reported by clients had the same issue.
400.00 on two invoices printed 490.00.
406.41 printed 496.41.
All cases where the 9 prints instead of the 0. He prints/creates approx 2,000 on each run weekly.

The only thing that I personally aware of is that they have added a new remote server, so they now have 2, but no idea which remote server he logs into when he does this..think its random. Does the job weekend when most users are off.

Could it be the processor or memory or some ugly demon?

Fred
Omni

Re: Reopen A subject

Posted: Tue Dec 10, 2019 2:55 pm
by rdonnay
If this workstation is running Windows 10, then I suggest that you use "Microsoft Print to PDF" in place of Win2PDF.

If you still see the same problem then I'm thinking there could be a rounding problem in my print engine. All numeric values must be converted to character strings when using the XbpPrinter() class. Possibly that conversion is creating the problem.

Re: Reopen A subject

Posted: Wed Dec 11, 2019 11:21 am
by omni
The reprints work fine when he gets the complaint from the customer..says its embarrassing.

@ 51, 60, 54, 80 DCPRINT BOX LINEWIDTH 6

@ 52,62 DCPRINT SAY "TOTAL" Printer oPrinter FONT "10.Arial Bold"
@ 52,77 DCPRINT SAY OPPRO->OPBILLTAMT PICTURE '99999.99' Printer oPrinter FONT "10.Arial Bold" ALIGN DCPRINT_ALIGN_RIGHT

That is the actual code when printing the invoice total.


When sending to the txt file it that particular item is Alltrim(Str(oppro->opbilltamt,10,2)) and matches the amount that it should.


Are you suggesting changing the oppro->opbilltamt to a string command/variable like above?

Fred

Re: Reopen A subject

Posted: Wed Dec 11, 2019 12:45 pm
by rdonnay
Change this:

@ 52,77 DCPRINT SAY OPPRO->OPBILLTAMT

To this:

@ 52,77 DCPRINT SAY Alltrim(Str(oppro->opbilltamt,10,2))

Let's see if that makes a difference.

Re: Reopen A subject

Posted: Wed Dec 11, 2019 12:50 pm
by omni
Will give it a shot..may be weeks or months before we hear anything if it did not work 100% of the time..hopefully we will hear nothing.

Thanks