Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Stop Message while saving Service Order from IW51

sachin_yadav3
Active Participant
0 Likes
2,257

Hello,

I am getting bleow error while saving service order.

System: Status object does not exist. Message Numner IW351

Actually I have done one enhcement in the User exit of the Sales order in the form Routine...

USEREXIT_SAVE_DOCUMENT_PREPARE

From this depending upon the some validation i am populating Error message,

I am creating sales order through service order from the Transaction IW51.

When i Try to save the service order i get the error messages which is coming from my validation which

I had put in the MV45AFZZ.

After the error messgae i press ENTER and then try to change the order by clcicking on the advance shipment.

As soon as i click on that i get a STOP messgae.

Which i as below.

System: Status object does not exist

I m not getting why it is coming.

Kindly Help.

Regards

Sachin

15 REPLIES 15
Read only

madhu_vadlamani
Active Contributor
0 Likes
2,121

Hi Sachin,

Can you paste the code.Did you check by commenting the code in the exit.

Regards,

Madhu

Read only

0 Likes
2,121

If I comment my code then this is not comming.

It triggers because of any error message.

If I comment all my code and put only error message messag then it comes.

actually this is a result of error message.

If I put error message in another exit USEREXIT_SAVE_DOCUMENT then same problems comes.

so it has no link with code. whenever error message will come in service order screen it will display standard message.

pls suggest.

Read only

Former Member
0 Likes
2,121

Hi Sachin,

Comment the code in the exit and check if u dont get the error then it is problem with ur code. Paste the code to check where u have gone wrong.

Thanks & Regards,

Neela

Read only

0 Likes
2,121

If I comment all my code and write only error message then it comes.

but it does't come for information and warning message.

actually steps are

1. go to IW51

2. create notification then service order then sales order

3. if product hierarchy is different for material then it should display error on saving

4. it is giving error message(my error message)

5. if i press enter and then click on advance shipment icon(truck) for change it display standard message.

which turn me out of transaction.

but if i click on advance shipment icon without pressing enter its working fine..

pls suggest.

Read only

0 Likes
2,121

Hi Sachin,

In ur error message what is the fm you have used. Do you have yes no options? I f u have wht is the code u have written for yes and no.

Thanks & Regards,

Neela

Read only

0 Likes
2,121

its simple error message. message e038(zcrm)

" service line must be same".

Read only

0 Likes
2,121

Hi ,

You can try the below option :

MESSAGE ixxx(xxx) with param1 param2 param3 DISPLAY LIKE 'E'.

Thanks ,

Suchi .

Read only

0 Likes
2,121

Can we call the error message in the sales order exit save_prepare?

I am not getting why any error messgae in not working for that?

Kindly help

Read only

0 Likes
2,121

If i try

MESSAGE ixxx(xxx) with param1 param2 param3 DISPLAY LIKE 'E'.

It will not stop my processing, I want to stop my processing if i am getting this error,

Regards

Sachin

Read only

Former Member
0 Likes
2,121

Hi,

After MESSAGE add STOP. :

MESSAGE ixxx(xxx) with param1 param2 param3 DISPLAY LIKE 'E'. 
STOP.

or If ambiguity with usage of STOP being obselete use EXIT after message.

MESSAGE ixxx(xxx) with param1 param2 param3 DISPLAY LIKE 'E'. 
EXIT.

BR

Dep

Read only

0 Likes
2,121

Hello,

I tried by putting STOP, EXIT, leave to screen , SET Screen but no success.

Please advice..

Regards

Sachin Yadav

Read only

0 Likes
2,121

Any inputs?

Regards

Sachin

Read only

0 Likes
2,121

After raising error message where do you need to go?

Max

Read only

0 Likes
2,121

After raising the error message it should stop processing and remain in the Service order screen,,,

It should not allow to save the service order/Sales order .

(I m creating Sales order from Service order through Tcode IW51. On Service order Screen i am saving which in turns save the sales order. Service order screen contains table control. )

Regards

Sachin

Read only

0 Likes
2,121

Is there any implicit or Explicit Enhacement where i can perform validation on all sales order line item?

Regards

Sachin Yadav