Small sample, did you execute every step ?
gv_repid = sy-repid. gr_table->set_screen_status( pfstatus = 'ZSTATUS' report = gv_repid set_functions = gr_table->c_functions_all ). lr_functions = gr_table->get_functions( ). lr_functions->set_all( abap_true ). TRY. lr_functions->set_function( name = 'ZFUNCTIONCODE' boolean = space ). CATCH : cx_salv_wrong_call, cx_salv_not_found. "#EC NO_HANDLER ENDTRY.
Regards,
Raymond