i have 2 fields on selection screen of a Report along with
a check box.My requirement is initially that first field
sud be mandatory but when we click on the check box the
first field which was mandatory sud now be optional and the
second field now sud be mandatory.Please provide the
solution asap. thank u.

Answer Posted / sunil kumar gautam

This example will be help full for this problem.
PARAMETERS check1 AS CHECKBOX USER-COMMAND check.
select-OPTIONS regio for kna1-regio MODIF ID mad.
select-OPTIONS kunnr for kna1-kunnr MODIF ID kad.
AT SELECTION-SCREEN .
"LOOP AT SCREEN.

if check1 = 'X'.
if kunnr is INITIAL.
Message 'Customer is manditory' type 'E'.
endif.
endif.

if check1 is INITIAL.
if regio is INITIAL.
Message 'Region is manditory' type 'E'.
endif.
endif.

Is This Answer Correct ?    0 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the system table used in abap?

790


What is the difference between upload and ws_upload ? : abap bdc

863


How does the interection between the dynpro and the abap/4 modules takes place?

877


What is the table buffer?

748


What are subroutines? : abap modularization

807






Explain the different types of mode (run code) in call transaction method?

753


What are the main uses of the primary key?

956


What are the objects of the abap dictionary or what types of objects can be created in the abap dictionary? : abap data dictionary

697


Can you set up background processing using call transaction?

769


what is the difference between Blocked ALV and interactive ALV?

2090


What are the basic objects of the data dictionary?

738


Does sap handle multiple languages?

737


What is a table attribute?

793


Explain the Importance of pa20? : abap hr

825


How to use messages in lists?

784