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

reg refresh button

0 Likes
2,093

hi team,

when i click on refresh button both header and item data should be cleared in module pool screen .it should show blank in input screen in all fields ,please give solution

7 REPLIES 7
Read only

anujawani242683
Active Participant
0 Likes
2,032

Hi Alazhu,

Clear work area. for example work area name is Z_T_E_M.

just write

clear Z_T_E_M.
 

Read only

0 Likes
2,032

this is my zalast_ekko,zalast_ekpo.tables

this my coding

CASE sy-ucomm.
WHEN 'RE'.
clear :zalast_ekko,zalast_ekpo.
ENDCASE.

whether it is correct or not give me a correct coding

Read only

0 Likes
2,032

Hi Alazhu,

Zalast_ekko and zalast_ekpo are internal table or work area ?

If it is a work area then write

CASE sy-ucomm.
WHEN 'RE'.
clear :zalast_ekko,zalast_ekpo.
ENDCASE.

if it is a internal table then write

CASE sy-ucomm.
WHEN 'RE'.
refresh :zalast_ekko,zalast_ekpo.
ENDCASE.
Read only

0 Likes
2,032

in item table how to clear the records using an table control.

it is clearing in header table but not clearing in item table, can you please give me a solution fast

Read only

0 Likes
2,032

Hi Alazhu,

To clear data from table control.

delete zalast_ekko.

delete zalast_ekpo.

Read only

0 Likes
2,032

According to SAP Clean Code, if I'm not wrong, REFRESH should not be used. Header lines are obsolete.

"work area" doesn't mean anything without context. Usually, this term is used only in abstract context like ABAP documentation. Better use the term "global variable corresponding to the screen field" (same name as screen field).

"delete itab" should not be used also because not explicit. It works only inside a loop.

alagu123 If you need exact solution, you should provide all possible details, otherwise it's impossible to help you as nobody can see what you did (unless having a crystal ball).
Read only

RaymondGiuseppi
Active Contributor
0 Likes
2,032

Where are you stuck (just clear variables and refresh internal tables in the PAI when processing this ok_code, so at next PBO they will be displayed with initial values)