R04572C Automatic cheque printing

adeel

VIP Member
Hello there

I have a problem that we have vendor software which reads the PDF file to create cheques from above object. We have cheques over million dollar.
The default length for the wording field e.g "One million and two hundred....." was 73 in the object, i increased the length to 83 and make field's font size to 8. solved my problem, But now i have to display length to 89 and font size to 7 so it can handle all sceniorio in the future e.g if cheques have more wording. But instead of printing the wording it is showing the numberic value of the amount.

I believe there must be setting in the JDE system? or the display length have limitation? Any idea will be appreciated.

Please help!
 
Where is the good answer
smile.gif



Thanks
 
The BSFN that coverts the num to words are all X00500 based (per language)

There is an internal flag in there called bLenFlag, that determines number (if too long) or the word format

It doesn't seem to be getting this figure from anywhere in particular and someone with better C++ skills than myself maybe able to identify what flips that flag to false

Only logic I can see that flips the flag is if nLenTot > 10

I think that's something like
ONE HUNDRED TWENTY = 3
TWO THOUSAND ONE HUNDRED TWENTY = 4
and so on

so
NINETY NINE MILLION xxxx exceeds the 10

Here is logic from the BSFN: Which is very well documented BTW
* if false, then the size of the array trying to be translated is greater than the alloted 99 million. Anything bigger is to be sent back as it was passed in (in number format).*/

This for loop does the main processing for the program The szConverted string had 300 spaces available that can hold the complete translation without space limitations. The szCvtWords array has only 18 spaces. The structure of the array is: [17],[16][15][14],[13][12][11],[10][9][8],[7][6][5],[4][3][2].[1][0] (trillion) (billion) (million) (thou) (hundred) The [17] is not used as it is quadrillion. The current structure of the program can handle up to and including (15) 9s (999.9 Trillion) and 99 cents. At positions 15, 12, 9, 6, and 3 there is checking to see whether those values and the position one less than it is a value between 11 and 19. If so, there would be no need to print the values at the one less position because the 'teen' value would be printed from the current position. Due to dependency of other objects on this business function, this will only translate numbers up to and including 99,999,999.99. Instructions on how to unlock this program to enable it to translate higher numbers is explained below. */ /* The bLenFlag is a conditional test to allow or not allow numbers to be translated. The criteria for the test is the length of the numbers to be translated. If the numbers are 99 million or less, the numbers are allowed to be translated. If they aren't that short, they are sent to the if statement which appends numbers that aren't able to be translated. In this case, the if statement will get the entire number.
 
Hi John
Thanks for the detail answer, I believe it is failing due to the number of characters see below the example.

Value is 1878878.00
ONE MILLION EIGHT HUNDRED SEVENTY EIGHT THOUSAND EIGHT HUNDRED SEVENTY EIGHT AND 00/100

I bet it is bug in the funtion,It has 88 character i guess if we increase number of character lenght for the convertstring might fix the problem

Thanks
AD
 
Hi John
Read comment below it is exactly happening that if the value is 99 million as you have also mentioned get false. But in reality it is 1xxxxx million,
I guess it would be a quicker fix but dont know which array i need to increase. Find attach whole code if anyone can help.

Thanks



BOOL bLenFlag = TRUE;
/* if false, then the size of the array trying to be translated is greater
than the alloted 99 million. Anything bigger is to be sent back as
it was passed in (in number format).*/
 

Attachments

  • 187495-code.txt
    44 KB · Views: 29
Hello there

Here is the response i got from Oracle. I believe someone should have a solution.

Response:

If the amount in words exceeds the maximum allowed in the system, 83 (that is including the spaces in between words) the amoutn will print numerical. This is published in Doc ID 1410936.1, copied below:

Question 2: How does the system deal with translated amounts that exceed the maximum allowed 83 characters?

Answer 2: X00500 - Convert numeric values into words. If the string length of the amount that has been converted into words is exceeding the length of 83 characters, it will be printed as numeric values. If it is not exceeding the specific length the total amount is been converted properly into words and it will be printed in check.


Thanks
 
Looks like noone did any customization to fix the issue in attach function.


Thanks
AD
 
You may look into the Spanish BSFN X00500S1 and compare with yours - it looks like they applied a SAR to increase to 200 chars!

/*****************************************************************************
* Header File: X00500S1.h
*
* Description: Convert Numeric Value to Words - Spanish 1 (Female) Header File
*
* History:
* Date Programmer SAR# - Description
* ---------- ---------- -------------------------------------------
* Author 1/20/99 RO5658573 2685701 - Created
* 6/16/99 AC5861643 2799063 - Increased DSTR to 200 Char
* 11/30/2001 BR5735524 5628884 Unicode Business Function Re-work
 
X00500C - Convert Numeric Value to Words Singapore - appears to handle large converted text correctly. You have to concatenate the three DL01 (top middle and bottom lines)into a larger single text field.
 
Back
Top