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: 

Dynamic Document - unwanted border

MarcinPciak
Active Contributor
0 Kudos

Hi all,

I am facing a problem with removing border around Dynamic Document I created.

Below is my coding:


DATA: o_dd_document TYPE REF TO cl_dd_document,  
          o_custom_container type ref to cl_gui_custom_container.

    CREATE OBJECT o_custom_container
    EXPORTING
     container_name              = 'DD_CONTAINER'
     style                       = cl_gui_control=>ws_*   "here whatever style constant I put, I can't hide the border

    CREATE OBJECT o_dd_document.

"here I am adding some elements to document
...
"then I am displaying it
CALL METHOD o_dd_document->display_document
      EXPORTING
         parent             = o_custom_container.

I tried with setting style directly on DD, but it isn't working too.

My question is: is there a way I can hide this unwanted border?

Thank you in advance

Marcin

7 REPLIES 7

former_member188685
Active Contributor
0 Kudos

any idea why you want to hide the border.

0 Kudos

Hi,

In custom container I want to store and image (logo program + some link)

I could use cl_gui_picture class to display image without border, but the link would not work there.

Alternatively instead of DD I could create cl_gui_picture + cl_gui_html_viewer (both have option to hide the border) and place them and CUSTOM_AREA, but this is workaround I would like to avoid.

All in an image without a border just looks better, at least for me;)

Regards

Marcin

0 Kudos

ok. I am trying various options it is not working. ws_* styles are not doing any thing. i will check any other ways to do this and post if i find any .

Edited by: Vijay Babu Dudla on Oct 7, 2008 10:01 AM

0 Kudos

I know I've checked all of them too, but without an effect.

I was thinking of another solution:

- creating custom container

- creating html viewer placing it in cust.container

- create DD placing it in html viewer

This is what SAP automatically does when displaying DD.

But I couldn't place DD in html viewer myself.

BR,

Marcin

-


Hi all ABAPers,

I found a solution. I will write it here in case someone face similar problem.

When creating DD, SAP place it as described above (first custom container, then html viewer).

We can retireve this html viewer reference by using below:


data: o_html_viewer type ref to cl_gui_html_viewer.

"get actual instance where DD was placed
o_html_viewer = o_dd_document->HTML_CONTROL.

"now we need to set appropriate flag for html viewer in order it doesn't display border
  CALL METHOD o_html_viewer->set_ui_flag
  EXPORTING
    uiflag     = cl_gui_html_viewer=>UIFLAG_NO3DBORDER.

That's it. It will result in displaying DD without border around it:)

Regards

Marcin

Edited by: Marcin Pciak on Oct 7, 2008 7:40 PM

0 Kudos

Hello Marcin,

Nice solution, Thank you !

0 Kudos

Thanks Marcin!

This was exactly the same problem i had, and your solution was the only way i could solve it!

Greetings

MarcinPciak
Active Contributor
0 Kudos

Solution was added to last post, please see it!