cancel
Showing results for 
Search instead for 
Did you mean: 

event ON_STD_FUNCTION_BEFO doesn't trigger

0 Kudos

Hi all,

I need to add some check before ALV add a new line to the grid or remove one line from the gird, but the event ON_STD_FUNCTION_BEFO was not triggered.And during debuging, I found that if the std is 'APPEDN ROW' or 'INSTER ROW' or 'CHECK_DATA' or 'Remove' the event won't be triggered but if the std is 'export' or 'print', it will be triggered.

is there anything config should be done or anything else?

Thank you very much!

BR, Julia

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

I'm facing the same problem and I found useful info in OSS note [1358811|https://websmp130.sap-ag.de/sap(bD1pdCZjPTAwMQ==)/bc/bsp/spn/sapnotes/index2.htm?numm=1358811]

it seems that ON_STD_FUNCTION_BEFO and ON_STD_FUNCTION_AFTE are triggered only for functions considered as service such as settings, settings_open, settings_close, filter, filter_define, filter_delete, sort, sort_define, sort_delete, pdf, export, export_excel...

functions for deletion or inserting of rows are not treated this way and doesn't trigger any event. Function check is not treated as service but triggers event ON_DATA_CHECK.

the relevant code is the method implementation IF_SALV_WD_COMP_TABLE_EVENTS~DO_FUNCTION_STD of class CL_SALV_WD_C_TABLE_V_TABLE.

I think the only way to solve this is disabling standard function and replacing it with a custom function.

Hope this helps.

Stefano

0 Kudos

Hi Stefano,

You are right. What I did to solve the problem was creating customized function.

Best regards

Julia