Demo on Search help exit for the material

...Previous

Code:

DATA : WA_TEMP LIKE RECORD_TAB,
       IT_TEMP LIKE RECORD_TAB OCCURS 0.
IF CALLCONTROL-STEP = 'DISP'.
IF SY-UNAME = 'XXXXXX'.
LOOP AT RECORD_TAB INTO WA_TEMP WHERE STRING+3(4) = 'FERT'.
APPEND WA_TEMP TO IT_TEMP.
CLEAR: WA_TEMP.
ENDLOOP.
CLEAR: RECORD_TAB[].
RECORD_TAB[] = IT_TEMP[].
CLEAR: IT_TEMP[].
ELSEIF SY-UNAME = 'YYYYYY'.
LOOP AT RECORD_TAB INTO WA_TEMP WHERE STRING+3(4) = 'ROH'.
APPEND WA_TEMP TO IT_TEMP.
CLEAR: WA_TEMP.
ENDLOOP.
CLEAR: RECORD_TAB[].
RECORD_TAB[] = IT_TEMP[].
CLEAR: IT_TEMP[].
ENDIF.
ENDIF.

Save and activate it.

Then place the Function module above location in SE11.

Testing:

Go to any Transaction which has material number.

Ex: ME21N. Press F4 on Material Field.

User1 Result:

User2 Result:

Please send us your feedback/suggestions at webmaster@SAPTechnical.COM 

HomeContribute About Us Privacy Terms Of Use • Disclaimer • SafeCompanies: Advertise on SAPTechnical.COM | Post JobContact Us  

Graphic Design by Round the Bend Wizards

footer image footer image