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

Raising event whenever a document gets changed

Former Member
0 Likes
889

hi all,

how can we check whether any contents of table gets changed without using an abap report.

the req is that i need to send a mail to another department whenever the content of table gets changed

thanks in advance.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
838

hi,

In order to record / log changes which are made to a business object an change document object must be created.

then this change document object is then assigned to an event and then appropriate action ie. create/change/display is defined.

the assignement between the change document is done using the tcode : SWEC

so when an events get triggered based on whether the object was changed, displayed, created then a function module can be called . this can be done by using SWETYPV.

in this function module we can then write the custom coding that we need.

1. you create a object using SWEC and then assign an event to it in SWEC for change.

2. then using SWETYPV you assign a receiver function to that event.

3. now write the required custom coding in your function module.

Hope this will help you!!!

Thanks & Regards,

Punit Raval.

hi all,

how can we check whether any contents of table gets changed without using an abap report.

the req is that i need to send a mail to another department whenever the content of table gets changed

thanks in advance.

3 REPLIES 3
Read only

SuhaSaha
Product and Topic Expert
Product and Topic Expert
0 Likes
838

Hello Rocky,

If this is a custom table then you can put the code in the 'events' of the TMG.

BR,

Suhas

Read only

former_member229729
Active Participant
0 Likes
838

Hi,

Try to create a Table Maintenance & an Event for the table.

Under the Event, you can write your coding for sending a mail whenever a Record is created.

Rgds,

Ramani N

Read only

Former Member
0 Likes
839

hi,

In order to record / log changes which are made to a business object an change document object must be created.

then this change document object is then assigned to an event and then appropriate action ie. create/change/display is defined.

the assignement between the change document is done using the tcode : SWEC

so when an events get triggered based on whether the object was changed, displayed, created then a function module can be called . this can be done by using SWETYPV.

in this function module we can then write the custom coding that we need.

1. you create a object using SWEC and then assign an event to it in SWEC for change.

2. then using SWETYPV you assign a receiver function to that event.

3. now write the required custom coding in your function module.

Hope this will help you!!!

Thanks & Regards,

Punit Raval.