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: 

How to reduce the width of Docking Control Container

Former Member
0 Kudos

Hi All,

I created a text editor control using docking container. Its width is occupying the entire screen. I want to reduce it to half of the screen. I tried changing the values of ratio, extension and used the methods set_width to change it, but was not successful. Please let me know how can i reduce the width. Below is the code which i am using.

data: editor TYPE REF TO cl_gui_textedit,

lo_dock TYPE REF TO cl_gui_docking_container.

IF lo_dock IS INITIAL.

CREATE OBJECT lo_dock

EXPORTING

repid = sy-cprog

dynnr = sy-dynnr

ratio = 75

extension = 50

  • metric = cl_gui_docking_container=>metric_mm

side = cl_gui_docking_container=>dock_at_bottom

name = 'DOCK_CONT'.

IF sy-subrc <> 0.

MESSAGE 'Error in the Docking control' TYPE 'S'.

ENDIF.

CREATE OBJECT editor

EXPORTING

parent = lo_dock

EXCEPTIONS

error_cntl_create = 1

error_cntl_init = 2

error_cntl_link = 3

error_dp_create = 4

gui_type_not_supported = 5

OTHERS = 6.

CALL METHOD editor->set_text_as_r3table

EXPORTING

table = i_texttable

EXCEPTIONS

error_dp = 1

error_dp_create = 2

OTHERS = 3.

1 ACCEPTED SOLUTION

former_member216702
Active Participant
0 Kudos

Hello,

You can put a splitter for manage the size.

Thierry

3 REPLIES 3

former_member216702
Active Participant
0 Kudos

Hello,

You can put a splitter for manage the size.

Thierry

0 Kudos

Thanks. It worked using Splitter.

0 Kudos

hi,

can you please give the code, how you solved the issue using splitter