Skip to Content

problem to get error message in IDOC_INPUT_ORDERS

Hello All,

I am trying to stop the idoc by some conditions like given below code in one of the user exit. I am able to append the error record in standard errtab internal table.

I could see the appended error record also. But it is not throwing any error message. IDOC is created successfully. Please check the given code and correct me where i went wrong?

ExitName: EXIT_SAPLVEDA_001

*Check for existing Project Numbet and Version. If already exists in system throw the error in IDOC

IF ZE1EDK02-QUALF EQ '001'.

hxvbak = dxvbak.

v_bstnk = ZE1EDK02-BELNR.

select bstnk vsnmr_v into corresponding fields of table i_vbak from vbak

where bstnk = v_bstnk

and vsnmr_v = hxvbak-vsnmr_v.

describe table i_vbak lines l_lines.

if l_lines > 1.

sy-msgno = '209'.

sy-msgid = 'VG'.

raise user_error.

endif.

clear hxvbak.

ENDIF.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Jun 21, 2007 at 11:17 PM

    Hi Cris,

    I don't think by using Raise you will be able to raise the error. Better write Meesage of type E or the best option is delete the entry from the IDOC for which you don't want IDOC to be generated.

    Regards,

    Atish

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 23, 2007 at 04:33 AM

    hi cris,

    i have the same requirement,

    can u help me out in this problem,i am very much new to ale/idoc.

    my requirement is

    if idoc_data-segnam = 'e1edk02'.

    if e1edk02-qualf = '011'.

    xvbak-xblnr = e1edk02-belnr.

    endif.

    endif.

    waiting for your reply

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.