06-23-2010 2:51 PM
Hi All,
I have custom field in my selection-screen of LDB PNP.
Can you people please let me know how can I put the selection-screen modificaiton For ex:
i have created
parameters a as checbox.
select-options: p_btrtl for p0001-btrtl no-intervals.
now If the check box is selected then p_btrtl we can enter values or esle If check box is not selected then p_btrtl will be grayed out, ( I.e. SCREEN-INPUT = 0)
This is simple from ABAP without LDB. But with LDB can we achieve?????????????
Satish
Edited by: Satish Vasireddy on Jun 23, 2010 4:05 PM
06-23-2010 4:02 PM
i have used PNP... on this below report..
tables pernr.
PARAMETERS : p1 type i LENGTH 10.
PARAMETERS : a1 as CHECKBOX USER-COMMAND u1 DEFAULT 'X'.
START-OF-SELECTION.
get pernr.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
if screen-name = 'P1'.
if a1 NE 'X'.
screen-input = 0.
MODIFY SCREEN.
endif.
endif.
ENDLOOP.
06-23-2010 3:12 PM
your fields are simply additional fields and can be treated as usually (LOOP AT SCREEN ...)
06-23-2010 3:14 PM
Please try it once before answering ...I think it's not possible....:(
Satish..
Edited by: Satish Vasireddy on Jun 23, 2010 4:35 PM..
Edited by: Satish Vasireddy on Jun 23, 2010 4:44 PM..
Edited by: Satish Vasireddy on Jun 23, 2010 4:52 PM
06-23-2010 4:02 PM
i have used PNP... on this below report..
tables pernr.
PARAMETERS : p1 type i LENGTH 10.
PARAMETERS : a1 as CHECKBOX USER-COMMAND u1 DEFAULT 'X'.
START-OF-SELECTION.
get pernr.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
if screen-name = 'P1'.
if a1 NE 'X'.
screen-input = 0.
MODIFY SCREEN.
endif.
endif.
ENDLOOP.
06-23-2010 4:08 PM
Thanks ,
Actually this work fine for parameters:
But for select-options its not working
Satish
Issue solved by
ex: if p1 is select-option,
screen-name = 'p1-low'.
That's it
Thanks
Edited by: Satish Vasireddy on Jun 23, 2010 5:11 PM
06-23-2010 4:27 PM
you can use the following logic for the additional selection validation. I have done by using PNP LDB. Ex : I have done for one of the field in IT0377.
SELECT-OPTIONS: s_bplan FOR p0377-bplan.
*&----
*& Form check_selection_0377
*&----
This subroutine is used to check the selection screen
*----
FORM check_selection_0377.
LOOP AT p0377 WHERE pltyp IN s_bplan
AND levl1 IN s_lti
AND begda LE pn-endda
AND endda GE pn-begda.
CALL FUNCTION 'HR_CHECK_AUTHORITY_INFTY'
EXPORTING
tclas = 'A'
pernr = pernr-pernr
infty = p0377-infty
subty = p0377-subty
begda = pn-begda
endda = pn-endda
level = 'R'
EXCEPTIONS
no_authorization = 1
internal_error = 2
OTHERS = 3.
IF NOT sy-subrc IS INITIAL.
DELETE p0377.
ENDIF.
ENDLOOP.
selection not found and no value selected
IF sy-subrc NE 0.
READ TABLE s_bplan.
IF sy-subrc EQ 0.
REJECT.
ENDIF.
READ TABLE s_lti.
IF sy-subrc EQ 0.
REJECT.
ENDIF.
ENDIF.
ENDFORM. " check_selection_0377
Regards,
Preetham