Skip to Content
0
Former Member
Mar 11, 2015 at 01:01 AM

Work order control key generating a PR type

72 Views

Hi,

Please advise how this scenario can be resolved. We would like the system to generate a PR type of 'NB' when a work order with an operation of control key 'PM02' is created. Our configuration in "Plant Maintenance and Customer Service> Maintenance and Service Processing> Maintenance and Service Orders > General Data > Define Account Assignment Cat. and Document Type for Purchase Requisitions" is setup to have 'FO' type as a default.

We tried putting the code in ZXCOZU01 (EXIT_SAPLCOZF_001):

IF ( sy-tcode = 'IW21' OR

sy-tcode = 'IW22' OR

sy-tcode = 'IW26' OR

sy-tcode = 'IW28' OR

sy-tcode = 'IW31' OR

sy-tcode = 'IW32' OR

sy-tcode = 'IW34' OR

sy-tcode = 'IW38' )

AND afvgd_imp-steus = 'PM02'.

eban_ord_cust_chg-bsart = 'NB'.

ENDIF.



but when trying IW31, it doesn't seem to go through this code when I release the work order to generate the PR.

Thanks!