cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Alignment problem in script

Former Member
0 Likes
1,868

Hi Experts,

While printing the item level details in the Main window , I am getting incorrect alignment for the last column (Net amount) as shown here.

I am using same logic for all the remaining columns, I don't know why only this last column is getting incorrect alignment.

Also I have tried swapping Discount column and Net amount, then also no change in last column alignment (i.e. Discount column in this case) .

Code using here is

Kindly help me on this.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Likes

Hello All,

Thanks you very much for your replays . I got the output . This is what i did .

In tabs-tab positions I entered type CH so it was affecting the allignment . now i changed to IN . So now all area alligned perfectly .

Thanx again for your quick responses . 🙂

Answers (3)

Answers (3)

Former Member
0 Likes

Hi

I think for the paragraph LI the last tab position alignment is set to CENTER.

please change alignment to RIGHT in the Tcode SE71 - Paragraph formats -> Tabs...

If the above does not work.

Please define a temp variable char(25) write a perform to pass the value and change it to text

and use the temp variable to be printed on the form in the required last column

Try them may be one of the above should work.

Thanks & Regards,

Veeru.

iftah_peretz
Active Contributor
0 Likes

Hi,

Try the following options:

  • delete the ,, from th LI line and put it before the = line
  • add ,,before the = line
  • add ,,after the = line
  • change = to LI
  • a mix of all these combinations, for example, add ,,before the = line and add ,,after the = line.

Best,

Iftah

Former Member
0 Likes

I have tried the above mentioned,but no use.

Can you suggest some more methods .

iftah_peretz
Active Contributor
0 Likes

Hi,

Is this SapScript? Or text editor? where are the values of REGUD are coming from?

I need to know so I could guide you accordingly.

Best,

Iftah

former_member576008
Active Participant
0 Likes

Hi,

Have you tried by increasing tab spacing(two commas) for the last column...i mean the tab position in paragraphs.

I think your alignment is correct..just try increasing the tab positions for last column.

regards,

Nandha

Former Member
0 Likes

Hi Peretz ,

Its SAP script . Please help me on this .

Former Member
0 Likes

Hi Kishore ,

Even tried by increasing the tab positions for last column. still same .

iftah_peretz
Active Contributor
0 Likes

Ok this is what I thought, but wanted to ask first.

You can try, for the time being, few options:

The first in the abap program in which the report is called  (before the 'open_form', 'write_form' functions)

and insert the line: CONDENSE regud-wnett.

The second option is within the SapScript to use a temporary variable to do that condense to, before the PROTECT part insert a form like so:

/: DEFINE &TMP& = &REGUD-WENTT(15)&

/: PERFORM GET_WNETT IN PROGRAM ZWNETT

/: CHANGING &TMP&

/: ENDPERFORM

And then in the PROTECT part replace  &REGUD-WENTT& with &TMP&.

Where in SE38 you would have to create the report ZWNETT:

REPORT ZWNETT.

FORM GET_ZWNETT TABLES IN_PAR STUCTURE ITCSY

OUT_PAR STRUCTURE ITCSY.

     CONDENSE OUT_PAR-VALUE.

     MODIFY OUT_PAR INDEX SY-TABIX.

ENDFORM.

A third option is just to use the DEFINE without the PERFORM statement.

Let me know is that helping you,

Iftah

former_member576008
Active Participant
0 Likes

Hi,

just give a try like this... &DATA(LC)&

C-compress to get rid of leading spaces.

L-left alignment

regards,

Nandha

Former Member
0 Likes

Hi,

Can you check the Paragraph format LI and check the Tabs button.

Check if you have any Alignment mentioned for the last entry.

If its blank may be you can try adding RIGHT alignment .

Thanks,

Shambu

Former Member
0 Likes

Even after making changes ,it is not coming correctly

Former Member
0 Likes

Try using the Alignment DECIMAL in the paragraph format and check.

Also, you can try giving &REGUP-WNETT(R)&.

Thanks,

Shambu

Former Member
0 Likes

Hi Shambu ,

Tried with DECIMAL in the paragraph format and &REGUP-WNETT(R)&. .. still same problem .