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

User Exit for VA41

Former Member
0 Likes
699

Hi ,

I have the following requirement .

If tcode is VA41 And VBAK-AUART = ZEOA or VBAK-AUART = ZEOR or VBAK-AUART = ZSCP,

mail should be sent to certain receivers.

Please let me know it there is there any Exit for the above issue

Thanks and Regards ,

Indira Priyadarshini.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
602

Hi,

Use MV45AFZZ in this FORM USEREXIT_MOVE_FIELD_TO_VBAK ....in this check for

tcode to be VA41 and vbak-auart according to your conditions....and use the function module

CALL FUNCTION 'SO_NEW_DOCUMENT_SEND_API1'
EXPORTING
document_data = doc_chng
put_in_outbox = 'X'
commit_work = 'X'
TABLES
object_content = t_mail_txt
receivers = reclist
EXCEPTIONS
too_many_receivers = 1
document_not_sent = 2
operation_no_authorization = 4
OTHERS = 99.

Thanks,

Shailaja Ainala.

4 REPLIES 4
Read only

Former Member
0 Likes
603

Hi,

Use MV45AFZZ in this FORM USEREXIT_MOVE_FIELD_TO_VBAK ....in this check for

tcode to be VA41 and vbak-auart according to your conditions....and use the function module

CALL FUNCTION 'SO_NEW_DOCUMENT_SEND_API1'
EXPORTING
document_data = doc_chng
put_in_outbox = 'X'
commit_work = 'X'
TABLES
object_content = t_mail_txt
receivers = reclist
EXCEPTIONS
too_many_receivers = 1
document_not_sent = 2
operation_no_authorization = 4
OTHERS = 99.

Thanks,

Shailaja Ainala.

Read only

0 Likes
602

Hi Shailaja,

Thanks for quick reply.

I have used the same include MV45AFZZ .

But it is triggerring even for VA01 .

How can I check the condition for tcode ie only for VA41 tcode the coding written should trigger.

Thanks and Regards,

Indira Priyadarshini

Read only

0 Likes
602

Hi,

You need to check like

if sy-tcode = 'VA41'.

endif.

write your logic between this...

Thanks,

Shailaja Ainala.

Read only

0 Likes
602

Thanks