Skip to Content
0
May 11, 2011 at 05:10 PM

Integrate html tags in a string and display it in a multiline text area

780 Views

Hi ABAPers!!

First of all let me tell you that I'm working in ACCENTURE Casablanca(Morocco) and this is my first Job in my career.

I'm working on an ALV OO, the program consists on creating an ALV using OO, In my selection screen there's a parameter of type ddobjname I provide the name of table and it returns the table's fields in another dynpro (screen0100), To do this I used the FM: 'DDIF_FIELDINFO_GET' then I append the internal table returned in another one to add the field CB (CheckBox), and I add a button in the toolbar, the function of this button is to generate a MySQL script To create the table provided by the user in my parameter (Screen 1000), but the fields of this table(MySQL) in the generated script are only the selected ones by cheking the checkbox in the ALV.

I store my script in a string.

My problem is that I want to show my script in a text area, but I don't know how to create a multiline text area!!

And I want to use HTML tags in my string.

I don't want to my string like this :

CREATE [TEMPORARY] TABLE [IF NOT EXISTS] SPFLI ( CONNID CHAR ( 4 ) NOT NULL PRIMARY KEY , FLTIME INT ( 10 ) , DEPTIME DATETIME ( 6 ) , DISTANCE DOUBLE ( 9 ) , FLTYPE VARCHAR ( 1 ));

But I want it to be shown like this:

CREATE [TEMPORARY] TABLE [IF NOT EXISTS] SPFLI (
CONNID CHAR ( 4 ) NOT NULL PRIMARY KEY , 
FLTIME INT ( 10 ) , 
DEPTIME DATETIME ( 6 ) , 
DISTANCE DOUBLE ( 9 ) , 
FLTYPE VARCHAR ( 1 ));

Thanks in advance

Regards

SMAALI Achraf

Edited by: SMAALI90 on May 11, 2011 7:12 PM