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: 

Alignment in sap smartforms?

tamilselvanm
Participant
0 Kudos

Hi Experts,

I have to design the smartforms in the following format.

Hard code             Value

Material Number : <Material Number>

Description         : <Description>

Material Type      : <Material Type>

In the above format, I am not able to align in value column from colon. The symbol of colon should be the same line. How to achieve it, Please explain me ASAP.

1 ACCEPTED SOLUTION

sriram_ramesh
Participant
0 Kudos

Use template inside loop thambi

7 REPLIES 7

Hvshal4u
Active Participant
0 Kudos

Hi Tamilselvan ,

You can use Template in smartforms.

What you have to do is Create Template with two columns i.e. for heading & theirs respective values.

& put you varialbes in second column & hardcoded description in first column.

Thanks & Regards -

Vishal

0 Kudos

Hi Vishal,

Thanks for your valuable reply.

I have to retrieve the values from table. Generally, Template is static. I am using some internal tables in my form. How to pass the table values to template?

0 Kudos

Hello,

You are right, templates are static place holders. for multiple line items from the internal table you have to use 'Tables'. Create a table with two columns and pass your internal table to it. This will be dynamic and will display all your records.

eg

Thanks

Rajit

0 Kudos

Hi,

If you want to display multiple lines just put the template in a loop.

If you want to display one line or header data just create separated fields like what described then read table using indexing then pass the value from the table to the fields .

VenkatRamesh_V
Active Contributor
0 Kudos

Hi,

Try,

Count the characters of  the  words, make the fixed length common to all words.

Material Number :                                     16 characters

Description &space(03)&          :              13 characters

Material Type &space(03)&       :               13 characters

Hope it helpful,

Regards,

Venkat.V

sriram_ramesh
Participant
0 Kudos

Use template inside loop thambi

0 Kudos

Hi Experts,

Thanks for your all valubale replies.

I have used some internal tables to pass the values from tables. I have used table and separated two columns in smartforms. First column is for hard code and second column is for table values. Finally, The alignments have been perfect in my smartforms.