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

Retain Selection-Screen Values

Former Member
0 Likes
2,302

Hi All,

After executing a report, output list is generated .Now upon clicking on the 'Back' button the selection screen is reached with blank values.... May i know if there is any way we can retain the selection screen values which we submitted to the program before executing.

No "defalut" values are allowed as any variant can be selected.

Kindly Advice.

Regards

8 REPLIES 8
Read only

Former Member
0 Likes
1,291

Hi

check out if there is any event in reporting .. like after processing ...

if yes u can go ahead and write ur logic there..

Deepak

Read only

Sandeep_Panghal
Product and Topic Expert
Product and Topic Expert
0 Likes
1,291

Hi ,

try using memory id or matchcode.

Rgds,

Sandeep

Read only

Former Member
0 Likes
1,291

Hi R.p.

There is no need of any code to hold the values in the seelctuon screen when you come back, have you tested your code.

Usually when we give the values in the selection screen and execute the program and click back the values are holded in the parameters or select options names workarea.

If you can show your code then we can find the bug.

Cheers!1

VEnk@

Read only

Former Member
0 Likes
1,291

Hi,

Not sure if anything supported by SAP to persist values of selection-screen.

But I think this can be acheived using IMPORT/EXPORT statement.

In INITIALIZATION event use IMPORT to retrieve values from memory

and in START-OF-SELECTION event use EXPORT to write values to memory.

Regards,

Vishal

Read only

Former Member
0 Likes
1,291

Hello,

You can use MEMORY-ID to store the values of selection screen. Selection screen values will always be lost because it hits the INITIALIZATION event when you press back button.

Thanks,

Jayant.

Read only

0 Likes
1,291

Hi Jayanth,

I've checked few programs which are retaining the sel-screen values but i didnt find any usage of Memory Id concepts.

Just wondering if this is any GUI related and session independent.

Kindly Advise.

Regards.

Read only

0 Likes
1,291

Hello,

You can just use "EXPORT TO MEMORY-ID ..." just after your START-OF-SELECTION event to store the selection screen vaules in a memory ID and in the INITIALIZATION event use 'EXPORT FROM MEMORY-ID .." to get the value from memory id and again assign it to the selection screen parameter defined.

Give it a try. Has worked for me.

Thanks,

Jayant.

Read only

former_member435013
Active Participant
0 Likes
1,291

Hi,

do this on leaving:

DATA: g_sel_tab TYPE TABLE OF rsparams.

...

CALL FUNCTION 'RS_REFRESH_FROM_SELECTOPTIONS'

EXPORTING

curr_report = sy-repid

TABLES

selection_table = g_sel_tab

EXCEPTIONS

not_found = 1

no_report = 2

OTHERS = 3

.

IF sy-subrc is INITIAL.

SUBMIT (sy-repid) WITH SELECTION-TABLE g_sel_tab VIA SELECTION-SCREEN.

ENDIF.

Regards

Walter Habich