Application Development and Automation 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: 
Read only

display data in a custom container

Former Member
0 Likes
1,030

Hi All,

My requirment is to just display data in a custom container.

I could able to display data in change mode but not display mode.Can you please let me now how can i do that.

Thanks in Advance

KV

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
932

Which custom container you are using? Generally custom container have attribute to make them only read only.

4 REPLIES 4
Read only

Former Member
0 Likes
933

Which custom container you are using? Generally custom container have attribute to make them only read only.

Read only

0 Likes
932

Im using cl_gui_custom_container.

In PBO

-


here is my code whihc is fine for Change/Edit mode.

  • create control container

CREATE OBJECT g_editor_container

EXPORTING

container_name = 'DISP_CONT'

EXCEPTIONS

cntl_error = 1

cntl_system_error = 2

create_error = 3

lifetime_error = 4

lifetime_dynpro_dynpro_link = 5.

IF sy-subrc NE 0.

  • do nothing

ENDIF.

  • create calls constructor, which initializes, creats and links

  • a TextEdit Control

CREATE OBJECT g_editor

EXPORTING

parent = g_editor_container

wordwrap_mode = cl_gui_textedit => wordwrap_at_fixed_position

wordwrap_to_linebreak_mode = cl_gui_textedit=>TRUE

EXCEPTIONS

OTHERS = 1.

IF sy-subrc NE 0.

  • do nothing

ENDIF.

In PAI

-


CALL METHOD g_editor->get_text_as_r3table

IMPORTING

table = Text_table

EXCEPTIONS

OTHERS = 1.

IF sy-subrc NE 0.

ENDIF.

Text_table contains messages which r supposed to be displayed.

Based on certain logical operations i will display the messages.

Read only

0 Likes
932

Please use this method

CALL METHOD g_editor->set_readonly_mode

EXPORTING

readonly_mode = cl_gui_textedit=>true

EXCEPTIONS

error_cntl_call_method = 1

invalid_parameter = 2

OTHERS = 3.

Read only

0 Likes
932

Thanks Romit Kewalramani

n i have given full points ...

Thanks

KV