2009 Sep 26 4:58 AM
Hi,
How do I use the above event in the following scenario.
Scenario: I have a report program which has two radio buttons on the selection screen to which user command is assigned. On selection one, some fields should get disappeared on the selection screen. But one of the fields is a mandatory field, which doesn't allow to proceed unless we enter some value in that(which is redundant since anyway it will be disappearing).
I thought 'on exit command' event works, but the user command assigned to the radio button is not of type E.
Issuing a message at selection screen instead of making the field mandatory will work, but I don't want to do that.
Can anyone please tell me how to handle this?
Incorrect answers will be suitably punished.
Thanks,
Sumanth
Edited by: Julius Bussche on Sep 26, 2009 12:40 PM
Silly comment suitably modified.
2009 Sep 26 5:15 AM
do not make that field mandatory using obligatory. so now your radio button work is done.
now, how to make the field look like and work like mandatory field on execution:
at selection-screen output.
loop at screen.
if screen-name = 'P_MAN'. " lets say this is the field which you want to make mandatory.
screen-required = 2. "this will just put a tick mark on the input , looks like mandatory.
endif.
endloop.now, how to check the mandatory option.
at selection-screen.
if p_man is initial.
display your message to fill this.
endif.hope this helps...
and as per forum rules, kindly do not encourage people by talking about forum rules.
2009 Sep 26 5:19 AM
just to add to yadav's post,
in the last part:
where the message display part comes,
you can use:
message 'mandatory field needs to be filled' type 'S' display like 'E'. " this will make the message look like error message
2009 Sep 26 5:21 AM