Triggering of enhancement codes upon changes on certain field only
Considers the below statements in SAPMV45A, Screen 4900 (PAI module).
* IS2ERP Media enhancement
MODULE vbap-posex_pruefen ON CHAIN-REQUEST.
I implemented my code enhancement in module 'vbap-posex_pruefen'.
May I know is there a way to trigger the enhancement codes only when VBAP-KDMAT is changed (while changes on other fields such as vbap-matnr, vbap-posex etc will not trigger it)?
Kindly please let me know if you know how to achieve this.
Thank much, Nick
Currently I am not over my system, so I can't tell you the correct answer, but would request you to look into the following proposed solutions :
1. Check if system contains the unchanged value ( previous value ) in variable YVBAP, if yes, then you can put your piece in code inside If clause ( If YVBAP-posex_pruefe NE XVBAP-posex_pruefe ).
2. Otherwise you can also check, if there is some Exit in PBO, if yes, set unchanged value in memory and then again check for the changed variable in PAI block.
Hope it helps.
Thanking You All.