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

Refreshing the Text Editor

Former Member
0 Likes
1,455

Hi Everyone,

I have used a text editor in one of my module pool program.

The text editor is part of one of the subscreen of a tabstrip that displays after I enter some values on the initial screen.

Everything is fine but the problem arrives when I try to go back from the tabstrip to the initial screen.

Now when I provide different values and go to the tabstrip, all other values are displayed correctly but the text editor contains the same text as before, corresponding to the values enetred for the first time on the initial screen.

Thanks in advance.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,333

Hi,

In your PBO event, write code MODULE DISPLAY_DATA.

and then double click on DISPLAY_DATA and then write code

IF SY-UCOMM = 'NXT' OR SY-UCOMM = 'PRV'.

PERFORM FREE_OBJECT.

ENDIF.

and then double click on FREE_OBJECT and write code

CALL METHOD TEXT_EDITOR->FREE

EXCEPTIONS

OTHERS = 1.

CALL METHOD CONTAINER->FREE

EXCEPTIONS

OTHERS = 1.

CLEAR : CONTAINER,TEXT_EDITOR.

6 REPLIES 6
Read only

Former Member
0 Likes
1,333

hi,

You need to clear the text editor.If you are using CREATE OBJECT to create the text editor, then use method FREE to clear the content of the text editor.

Read only

Former Member
0 Likes
1,334

Hi,

In your PBO event, write code MODULE DISPLAY_DATA.

and then double click on DISPLAY_DATA and then write code

IF SY-UCOMM = 'NXT' OR SY-UCOMM = 'PRV'.

PERFORM FREE_OBJECT.

ENDIF.

and then double click on FREE_OBJECT and write code

CALL METHOD TEXT_EDITOR->FREE

EXCEPTIONS

OTHERS = 1.

CALL METHOD CONTAINER->FREE

EXCEPTIONS

OTHERS = 1.

CLEAR : CONTAINER,TEXT_EDITOR.

Read only

0 Likes
1,333

Thanks everyone.

Using CALL METHOD text_editor->free

EXCEPTIONS

OTHERS = 1.

followed by FREE text_editor solved the issue.

Thanks..

Read only

0 Likes
1,333

Thanks everyone.

Using CALL METHOD text_editor->free

EXCEPTIONS

OTHERS = 1.

followed by FREE text_editor solved the issue.

Thanks..

Read only

SuhaSaha
Product and Topic Expert
Product and Topic Expert
0 Likes
1,333

Are you populating the text editor based on user input & you want to refresh the value if the user input changes ?

Read only

Former Member
0 Likes
1,333

Thanks everyone.

Using CALL METHOD text_editor->free

EXCEPTIONS

OTHERS = 1.

followed by FREE text_editor solved the issue.

Thanks..