Application Development 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: 

ABAP screen work

anupam_srivastava2
Participant
0 Kudos

Hi All

I have some ABAP screen to develop. I have some fields in blockA like

Delivery

Shipping point

Delivery type

Plant

Scan Date

Delivery Creation Date

In Block B, I have radio buttons

Successfully Scanned

POD Awaiting scanning

Scanned but not expected

Duplicated records

When I select Successfully Scanned radio button - then Scan date field should be mandatory.

If I select POD Awaiting scanning then Delivery creation date field should be mandatory

and there are are other things as well.

Does any body have any idea how can we do that.

Moderator message - Please search before asking - post locked

Edited by: Rob Burbank on Jun 24, 2009 12:16 PM

3 REPLIES 3

Former Member
0 Kudos

Hi,

Add code in the PBO. Check whaich button is selected and depending upon that set required = Y.

When I select Successfully Scanned radio button - then Scan date field should be mandatory.

If I select POD Awaiting scanning then Delivery creation date field should be mandatory

and there are are other things as well.

loop at screen.

if screen-fieldname ' scan date'.

if scanned = 'X'.

screen-required = 'X'.

endif.

endif.

modify screen

endloop.

Regards,

Anil

0 Kudos

Sorry Anil if I have put my question in an incorrect way, I have not used screen painter, just simple abap code. is it possible for this ??


*----------------------------------------------------------------------*
* Selection screen                                                     *
*----------------------------------------------------------------------*
SELECTION-SCREEN BEGIN OF BLOCK bl1 WITH FRAME TITLE text-bl1.
SELECT-OPTIONS: s_vbeln FOR likp-vbeln,  "delivery no
                s_vstel FOR likp-vstel,  "shipping point
                s_werks FOR likp-werks,  "receiving plant
                s_erdat FOR likp-erdat,   "date
                s_dcdat FOR likp-erdat OBLIGATORY. "delivery creation date
SELECTION-SCREEN END OF BLOCK bl1.

SELECTION-SCREEN BEGIN OF BLOCK bl2 WITH FRAME TITLE text-bl2.
PARAMETERS: p_ok RADIOBUTTON GROUP G1,
            p_noscan RADIOBUTTON GROUP G1 DEFAULT 'X' ,
            p_noabc RADIOBUTTON GROUP G1,
            p_dup RADIOBUTTON GROUP G1.

*  PARAMETERS: p_ok AS CHECKBOX,        "successfully scanned
*              p_noscan AS CHECKBOX DEFAULT 'X',   "expecting scan
*              p_noabc AS CHECKBOX,     "unexpected scan
*              p_dup AS CHECKBOX.       "duplicate scan
SELECTION-SCREEN END OF BLOCK bl2.



*----------------------------------------------------------------------*
* Selection validation                                                 *
*----------------------------------------------------------------------*
AT SELECTION-SCREEN.


0 Kudos

Is it possible to do this using selection-screen??