Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Mandatory Malfunction Date & Time at the time of Teco

Hi SAP Folks,

I want to do mandatory the field of Malfunction Date and time at the time of order teco. When I click on teco flag the Popup comes ,here I want to do mandatory that field.I can do it mandatory at the time of order creation in header data using screen variant.but my requirement is on Popup.I take help of ABAP using following given link but its not working.

http://scn.sap.com/message/6788219

replied

Hello Gaurav,

Though this can be managed through several user-exits (IWO10004, IWO10009 and even QQMA0014), the very effective one I had implemented is through user-exit: IWOC0002 . Just put the code below in the include ZXWOCU10 and the job is done.

IF i_viqmel-qmart = 'M2' AND i_viqmel-ausbs IS INITIAL AND i_vrgng = 'PMM4'.
   MESSAGE 'Fill The Malfunction End Date & Time before Completing the Notification' TYPE 'I'.
   RAISE no_status_change
.

ENDIF.


This throws the following error pop-up when you try to Continue the screen posted by you in the query with blank Malfunction End date. (I hope you'd understand from the code that the code is meant for M2 Notification. You'd change the Notification type according to yours).



Extra information

Further, if you want this effect for M3 Notification also, (for stopping Notification or related Order from NOCO, TECO respectively, when Required End Date/time are not filled the code can be like this.

IF i_viqmel-qmart = 'M2' AND i_viqmel-ausbs IS INITIAL AND i_vrgng = 'PMM4'.
   MESSAGE 'Fill The Malfunction End Date & Time before Completing the Notification' TYPE 'I'.
   RAISE no_status_change.
ELSEIF i_viqmel-qmart = 'M3' AND i_viqmel-ltrmn IS INITIAL AND i_vrgng = 'PMM4'.
   MESSAGE 'Fill the Required End Date & Time before Completing the Notification' TYPE 'I'.
   RAISE no_status_change.
ENDIF
.

In fact I'm busy. May be responding late, if you have any further queries. (But I believe this would resolve)

Good luck

KJogeswaraRao

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question