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: 

Smartform Table line allignment problem...

Former Member
0 Kudos

Hi ABAP Gurus,

I am facing a wierd problem.

I have created a Table in Main window in smartform. After that I created two line type i.e LT1 and LT2 inside that table.

Then in the main area of table I am creating two table lines asociated with these line types.

Now , for one table line, I define the line type for it in output table say LT2.

In each cell in this table line I write some code and then populate the value in text, but I am facing following problem.

Item--ColorNestQtyUOMPKG--TOTAL

-


1041--BLACK1CNU--


PC

-


300--


2---3,400

Here you can see that QTy, PKG and Total values are not alligning on line one but are getting pushed to line 2.

I am wondering why is that happening ?

Can someone please guide me as whats the problem ?

Thanks.

Regards,

Tushar.

3 REPLIES 3

RichHeilman
Developer Advocate
Developer Advocate
0 Kudos

Its because the line is not big enough to hold all of the data. The quantity fields are bigger than they need to be, you can probably trim them down a bit.

Regards,

Rich Heilman

Former Member
0 Kudos

1. Condense the data and then try to display so that the leading / trailing spaces are not displayed.

2. Try to display data in the left-justified manner.

One of these steps should help you in the data getting wrapped into the second line.

Regards,

Ravi

Note : Please mark all the helpful answers

Former Member
0 Kudos

Hi Tushar,

The problem is with the value of the fields and the allocation. for ex.

the qty field would be decimal of length 10, but the value would be just 100 so the remaining space is getting occupied. so you will have to remove the leading space in that variable. so what you do is use this command

if the variable ws_qty has the value display the variable as this:

<b>&ws_qty(C)&</b>

So what happens is the initial space is condensed by this condition before being displayed so for all the variables which are not allingned use this syntax and it will display according to your allignment.

Reward if helfpul.

Regards,

Tushar