Application Development and Automation 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: 
Read only

Alignment in scripts

Former Member
0 Likes
2,589

Good afternoon gurus

how do we make alignment in scripts?

Thanks Preeti

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
2,268

well there are several possibilities

you can create paragraph formats. In those paragraph formats you can define Tabs.

To every single Tab defined you can choose between 4 alignments.

In SAP-Script itself you can use (R) like in &VARIABLE(R)& to make the alignment right.

a paragraph format itself can have an alignment as well.

9 REPLIES 9
Read only

Former Member
0 Likes
2,268

Hi,

You can align text in Scripts using paragraph formats, using tabs

Regards

Suruchi

Read only

Former Member
0 Likes
2,268

Hi

Define your own Paragraph Formats (za) and define the TAB settings and the FONT settings and allign the fields LIKE

ZA &ITAB-VBELN&,,&ITAB-POSNR&,,&ITAB-MATNR&,,&ITAB-MENGE&

Reward points for useful Answers

Regards

Anji

Read only

Former Member
0 Likes
2,269

well there are several possibilities

you can create paragraph formats. In those paragraph formats you can define Tabs.

To every single Tab defined you can choose between 4 alignments.

In SAP-Script itself you can use (R) like in &VARIABLE(R)& to make the alignment right.

a paragraph format itself can have an alignment as well.

Read only

0 Likes
2,268

I did the alignment using tabs but it is not giving me the right output when i use it for printing the values in my script

I am printing like this

,,&itab-matnr&,,&itab-maktx&

Tab settings are

1st 2 cm left

2nd 4 cm left

3rd 7 cm left

Now it is not printing 6 cm , it is printing 4 cm from the start of the page. Why ? 2+4 should make it 6

Please help.

Read only

0 Likes
2,268

Can anybody please help

Read only

0 Likes
2,268

Hi,

,,&itab-matnr&,,&itab-maktx&

Tab settings are

1st 2 cm left means 1st tab starts at cm=2

2nd 4 cm left means 2nd tab starts at cm=4

3rd 7 cm left means 3rd tab starts at cm=7

Read only

0 Likes
2,268

Hi,

It is not going to print 6 cm from the start, it will print at 4 because the alignment that you give is from the left of the page not from the first tab.

<----->itab-matnr

2cm

<----


>itab-maktx

4 cm

<----


>XYZ

8 cm

Hope It is clear now.

Regards,

Suruchi

Read only

0 Likes
2,268

I got it now.

Thanks for all your help!!

Read only

0 Likes
2,268

tab positions are absolute and not relative that should make it all clear.