‎2012 Jul 19 12:26 PM
Hi to all,
I have the following need that I am not able to implement: in the screen of my report, I have a first input field populated with three values and I would like that, based on the value selected by the user in that input field, the next elements in the screen (another input field, few check boxes and a couple of radiobuttons) get activated, or set as invisible, accordingly.
The screen has been designed with the screen painter. I found in other threads that I should use LOOP AT SCREEN and then MODIFY SCREEN, but what I am not able to achieve is to get the value the user has chosen for the first input field, so that to modify the properties of the other elements.
Can you help me with this, giving me some code examples?
Thank you!
Regards,
JFlan
‎2012 Jul 19 2:44 PM
Hi,
but what I am not able to achieve is to get the value the user has chosen for the first input field, so that to modify the properties of the other elements.
Have you declare your input field in the calling program (with same type and length)?
e.g: DATA: w_rout TYPE ...
Kr,
Manu.
‎2012 Jul 19 12:30 PM
Hi,
You must code the loop at screen... endloop block in the PBO of the screen.
Can you please paste the flow of the screen in order to help you in more detail ?
regards.
‎2012 Jul 19 1:58 PM
Hi Laurent,
Here the flow logic:
PROCESS BEFORE OUTPUT.
MODULE status_1000.
PROCESS AFTER INPUT.
CHAIN.
FIELD w_rout.
FIELD w_test.
FIELD w_prod.
FIELD w_char.
ENDCHAIN.
MODULE user_command_1000.
When the report is run, the user shall choose a value for w_rout, then the other fields properties shall be changed according to certain rules.
Thank you for helping.
‎2012 Jul 19 2:17 PM
Hi again,
Change it like this :
PROCESS BEFORE OUTPUT.
MODULE status_1000.
MODULE Modify_screen.
PROCESS AFTER INPUT.
Create the module and write there the loop at screen... endloop coding that changes your fields.
Try it and reply.
‎2012 Jul 19 3:12 PM
Hi Laurent,
Thank you. I tried but noticed that the modify_screen module is only run before screen output, and not when field w_rout gets, or change, value. Do you have further clues?
Thanks
‎2012 Jul 19 12:31 PM
Hi,
Use the FM DYNP_VALUES_READ to read the values of the screen elements.
Cheers
~Niranjan
‎2012 Jul 19 3:26 PM
Hi,
Do you have an example? Where and how to call it?
Thanks a lot.
Bye
‎2012 Jul 19 2:44 PM
Hi,
but what I am not able to achieve is to get the value the user has chosen for the first input field, so that to modify the properties of the other elements.
Have you declare your input field in the calling program (with same type and length)?
e.g: DATA: w_rout TYPE ...
Kr,
Manu.
‎2012 Jul 19 3:23 PM
‎2012 Jul 19 3:27 PM
So once your input field is filled, you just need to press the enter key so that your PBO module is processed... What is your issue exactly?
Manu.
‎2012 Jul 19 3:36 PM
Oh I think I understood : your "input" field is a list box, isn't it?
If yes, have you assigned a function code to the list box?
Manu.
‎2012 Jul 20 5:55 AM
As said by Manu, assign function code and write code in PBO to modify screen
Regards,
Vinod
‎2012 Jul 20 7:08 AM