cancel
Showing results for 
Search instead for 
Did you mean: 

formatting options in sap scripts.

Former Member
0 Kudos

Hello,

I have problem in formatting amount values.

I want to display some line item amounts.

16,999.00

9,999.00

8,881.00

Now the problem is all amounts are not right alinged as shown above.

I defined tab as right aligned, but still the problem is coming.

Could you please help me to rectify this problem.

Thanks & Regards,

Sathish

Edited by: sathish kumar swamy on Sep 24, 2008 10:53 AM

Accepted Solutions (0)

Answers (7)

Answers (7)

Former Member
0 Kudos

Hi,

-> By default amount field will right justified

-> Please varifity the output length of each column and the tab lengh for each column

-> better to put each column lenght all information on paper

you can find the problem.

Netaji.B

Former Member
0 Kudos

Hi sathish kumar swamy,

You have to check the offset w.r.t left norder of the window.

Suppose you have 5 fields like F1,F2,...F5.

and F1 has length 12chars,F2 has length 2chars,..F5 has length 20 chars.

And F3 is Amount filed that offset should start after offset of F1+

offset of F2.

So check the offsets.

Hope this helps you.

Regards,

Rama.

Former Member
0 Kudos

try this:

&variable(10R)&

accordingly you can vary the nos in bracket i.e.12 or 15 whatever suits your requirement

Sid

Edited by: Siddhartha Prakash on Sep 24, 2008 11:48 AM

Former Member
0 Kudos

Hi Satish,

In the Paragraphs and select your paragraph format go to the TABS button and give the tab postion and Alignment as DECIMAL.

Regards,

Chandra Sekhar

Former Member
0 Kudos

Hi sathish ,

In the paragraph format give the alignment DECIMAL

Regards,

Sravanthi

Former Member
0 Kudos

Hi,

Please write below code n sub routine or in a window.

CALL FUNCTION 'CLSE_SELECT_USR01'

EXPORTING

USERNAME = SY-UNAME

IMPORTING

  • X_USR01 = X_USR01

  • DATE_FORMAT = DATE_FORMAT

DECIMAL_SIGN = l_v_dec

SEPARATOR = l_v_sep.

WRITE <Currency Filed> TO <Varaible type Char>.

SPLIT <Varaible type Char> AT l_v_dec

INTO <Varaible type Char1>

<l_v_char2>.

CONDENSE <l_v_char2>.

REPLACE ALL OCCURRENCES OF l_v_sep

IN <Varaible type Char1>

WITH l_c_comma.

CONCATENATE <Varaible type Char1>

<l_v_char2>

INTO <Varaible type Char1>

SEPARATED BY l_c_dot.

Display Filed <Varaible type Char1>

Shortly i come up with Examle.

Regards

jana

Former Member
0 Kudos

Both the paragraph format and tab format should be right alligned

Venu..