cancel
Showing results for 
Search instead for 
Did you mean: 

FormattedTextEdit Problem

Former Member
0 Kudos

Hi everyone,

In my Web Dynpro application I try to create a FormattedText from a String containing HTML Code:

My Input String kommentarFormatted is:

<table><tr><td>Test </td><td> testing </td><td>  Test</td></tr></table>

This String should be displayed in a FormattedTextView UI Element by using the WDFormattedTextFactory Class.

IWDFormattedText formtext = WDFormattedTextFactory.valueOf(kommentarFormatted);
wdContext.currentContextElement().setTempFormattedKommentar(formtext);

The Attribute tempFormattedKommentar is of type FormattedText.

But the Result displayed in the FormattedTextView is: TesttestingTest

All HTML Tags are cleared.

Do I need additional tags to make the UI Element accept the input?

Best regards,

Olaf

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

See [Supported Tags|http://help.sap.com/saphelp_nw04s/helpdata/en/08/5696420cc2c56ae10000000a155106/content.htm]

Former Member
0 Kudos

Thanks for you answer Aviad.

I tried using the <table> tags and it works in a different scenario.

From a FormattedTextEdit UI Element with a String type attribute I read the input:

String test = wdContext.currentContextElement().getTest();

After that I add some HTML tags like <table> <tr> and so on.

Then I set the attribute again and it works.

wdContext.currentContextElement().setTest(test);

The UI Element displays the Input with working table tags.

How about that? I'm a little confused cause <table> tags should not be supported.

Regards,

Olaf

Answers (0)