How to clear PARAMETERS & SELECT-OPTIONS

Question: Hi everyone

I have a report that returns a list. When I then go back to the selection screen, I would like all PARAMETERS & SELECT-OPTIONS to be cleared. Somehow the values always appear, even if I clear it at the end of my program. I don't use SPA/GPA.

Thanx,
JohnnyB

Answer:
Hi JohnnyB

Have You tried to refresh the internat tables containing Your selection ctriterias??

Best regards
Carsten

Answer:
Some parameters, based on the type they are declared, take default values from user's parameters.
E.g, if you define a parameter of type WERKS_D, it would take a default value from user parameter WRK if defined.

Hope it helps.
mr.

Answer:
Refresh the selection screen parameters in the AT selection-screen output event of your program. This will clear the values on the selection screen every time the screen is loaded. But you may have few problem with this, like unnecessarily the data may get cleared !! Just check whether that helps ...

~Ranganath

Answer:
Thank you for your replies! Clearing the itabs didn't help and there are no
user parameter settings, since they are no links to standard objects.

->ranganathkr:
I was afraid, you would suggest that! ;-) I thought I can avoid AT SELECTION-SCREEN OUTPUT, because the checks gonna be complicated, since it's being processed with each and every user input.

But thank you anyway

Answer:
Does something like this not do what you want?

What is very surprising to me is that I had first tried to clear the parameters P_TOTO and P_TATA in this INITIALIZATION event, but it did'nt work... Thus, it seems that the INITIALIZATION event is not very clear to me... Could someone explain me why I cannot clear my parameters in the INITIALIZATION event, although this event is processed when pressing the BACK button ?
Works as designed: If a standard selection screen is declared in an executable program, the same program will be automatically called again after it was completely processed. In this process, the user inputs are automatically buffered and are available again for the following selection screen.
See here
INITIALIZATION will be called every time when you push BACK while in the list processing. So, to make above code clear parameters always after return from list you have to remove FREE MEMORY ID statement from INITIALIZATION event.
_________________
Best regards, Sergey Korolev

Answer:
The event LOAD-OF-PROGRAM is processed only once, unlike INITIALIZATION. If you want to clear your memory id when you exit the program fill the form %_SEL_SCREEN_%_EXCOM_% (the form is called by the system).
_________________
MattG.
Search SAPfans

Answer:
Hello Sergey, hello Matt.

Thank you both for your explanations concerning the INITIALIZATION and LOAD-OF-PROGRAM events.

Best regards,

Benoît
Copyright ?2007 - 2008 www.jt77.com