Bernard :
>>
In the following code, I want to put 2 currency amounts into a text line,
right justified and zero filled. The fields are 11 spaces each.
The first amount should go into 1 thru 11 and the second amount should go
into 12 thru 22.
However, it seems that the format function is putting a sign field in front
of the digits and therefore truncating the last digit.
Anyone know how I can eliminate the extra space in front of the amounts?
<<
To my knowledge, the only way to delete this extra space is to use SGET
function.
The following command is used to build a fixed length file that is to be
transmitted and processed on a mainframe.
wlmtDECL is an INT variable that have to be writen at column 174, rigth
justified, 11 char. long and left padding with zero
SET VAR vwrite = +
(SPUT(.vwrite,(SGET(FORMAT(.wImtDECL,'00000000000'),11,2)),174))
SGET is to take only 11 char. starting at position 2 (to prevent the
leading space to be writen onto the file.
Yes I know .... Complicated .... but it works and I did't find any mode
simple solution ....
Hope this will help anyway.
J.M. GRATIAS, Logimatique, France
================================================
TO SEE MESSAGE POSTING GUIDELINES:
Send a plain text email to [EMAIL PROTECTED]
In the message body, put just two words: INTRO rbase-l
================================================
TO UNSUBSCRIBE: send a plain text email to [EMAIL PROTECTED]
In the message body, put just two words: UNSUBSCRIBE rbase-l