cancel
Showing results for 
Search instead for 
Did you mean: 

problem in formatting of long text -- line break not recognized.

Former Member
0 Kudos

Hi ,

We have a PO smartform in our SRM system and we are facing problem with formatting of long text on the smartform for long texts maintained for the PO.

for ex, we maintain the long text as --

"this is long text for item 1.

1. this is line 1.

2. this is line 2."

On the smartform it is displayed as --

this is long text for item 1. 1. this is line 1. 2. this is line 2.

So basically, the line breaks in the text are not considered in the smartform .

Any suggestions on how to fix this issue ??

Thanks.

Accepted Solutions (0)

Answers (4)

Answers (4)

Hi Harmeet,

Even I had the same issue and it got solved. Please use the below FM

CALL FUNCTION 'BBP_OUTPUT_LONGTEXT_MAP_SMART'
   EXPORTING
     it_longtext       = gv_longtext   "LongText Table which we get
  IMPORTING
    ET_LONGTEXT       = lt_longtext "Formated long text table

By using this all the blank lines and new lines are preserved

Its too late to reply. But anyone who is looking for the answer may get some help.

Regards,

Sushanth Herle P

Harsh_Bansal
Contributor
0 Kudos

Hi,

In the node, you can right click and select 'TEXT'.

Now select its type as 'Include Text'.

Here you can provide - Text name, Text id, Text id and language.

It will print those lines automatically in same format as maintained in long text.

regards,

Harsh Bansal

Harsh_Bansal
Contributor
0 Kudos

Hi,

Then i think by using Include text your problem will be solved.

It takes care of new lines.

Regards,

Harsh Bansal

Former Member
0 Kudos

Harsh,

Std FM returns an internal table with all text lines. How do you suggest using 'include text' in this case.

SuhaSaha
Advisor
Advisor
0 Kudos

Hello Harmeet,

Which Std. FM are you using to fetch the PO texts? If the PO doesn't exist in your system, i'm afraid you cannot use Include Texts as mentioned by Harsh.

As an alternative you'll have to create a table & pass the text lines to it! I don't think SmartForms are not smart enough to identify new-line character.

BR,

Suhas

Harsh_Bansal
Contributor
0 Kudos

Hi,

How are you reading long text in smartform??

Use Include Text.

Regards,

Harsh Bansal

Former Member
0 Kudos

We are using std. SAP FM to read the PO information , which includes the long texts as well.