Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

remove leading space(blank) REGUH-RWBTR in script

Former Member
0 Kudos

hi,

i am now dealing with cheque priting in word issue.

the output format should be :

<b>USD 111,000 AND CENT 45 ONLY.</b>

the amount field i use is REGUH-RWBTR in script. but the output come with leading of space.

<b>which is as : USD 111,000 AND CENT 45 ONLY,</b>

which this is not i want. how am i going to remove the blank space leading and ending for REGUH-RWBTR?

below is my current code:

&'***RM'REGUH-RWBTR(.0)&&' AND SEN 'SPELL-DECIMAL(2)& ONLY ***

please any one can help me. either using this field, or any other way to do display it?

1 ACCEPTED SOLUTION

Former Member
0 Kudos

try

REGUH-RWBTR(<b>C.0</b>)&&

if this is not working move the amount field into a variable declared as type char and use the option(C.0)

regards,

Vijay.

5 REPLIES 5

Former Member
0 Kudos

try

REGUH-RWBTR(<b>C.0</b>)&&

if this is not working move the amount field into a variable declared as type char and use the option(C.0)

regards,

Vijay.

Former Member
0 Kudos

hi,

Numeric values are normally right justified,to avoid this use formatting options.

for example &symbol& want to be left juctified write it as &symbol(L)&.

regards,

praveen

Former Member
0 Kudos

thank you very much. it works.

but ,how if i want to remove the ending space as well? because i remove the decimal at the end, but it still shows a blank space on it. is there a way to remove it?

thanks

0 Kudos

can i see the exact o/p as how u r seeing it for comparision.

i hope u r using &rxxxx-rwbtr(C.0)&

did u check the second option also . ? confirm

Since the data type is currency format and here we are supressing the decimals so in order to supress the blank space at the end you can go for a variable declaration with type char

say gv_val(13) type c

and then move the rxxx-btr to this gv_val as

gv_val = rxxx-rwbtr.

now replace in the code display the amount filed as &&gv_val(C.0)&&

Im not logged onto sap now.

you have to confirm the result.

regards,

vijay.

0 Kudos

yes......it work......thanks you so much for all the help.....