Hi Srikant,
please create a structure in your program, with a variable of type string, ebeln, ebelp ,
and declare these code
data:begin of dt_lines occurs 0,
tdformat like tline-tdformat,
tdline like tline-tdline,
data:end of dt_lines.
Again, create a internal table of the same type as of the structure created earlier,
lets say the internal table is it_tab1,
then collect all these stuff in the internal table and, inside the text in your smartforms
loop into the internal table, you have created, you will get the desired result.