Application Development 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: 

How use CL_WB_CHECKLIST returned by RS_WORKING_OBJECTS_ACTIVATE

0 Kudos

Hi SAP & Experts,

I use FM RS_WORKING_OBJECTS_ACTIVATE to perform a mass activation.

Sometimes I get erros, so I used p_checklist parameters that returns CL_WB_CHECKLIST object.

I could get the error list using :

 p_checklist->has_error_messages( ) = abap_true.
 p_checklist->get_error_messages( IMPORTING p_error_tab = t_errors ).

When I crawl each error I could the component who on error using : class

cl_wb_object

o_wb_object = t_errors-edit_req->get_object_ref( ).

But I can't get the main R3TR object like CLAS, PROG or FUGR. I get REPS with method's include for example (ZKO_1=========================CM001). Even using method

GET_REQUEST_KEY or get_display_name..

I could the object URI using :

o_ref = cl_adt_uri_mapper=>get_instance( )->if_adt_uri_mapper~map_wb_object_to_objref( o_wb_object ).
 s_error-position-uri = o_ref->ref_data-uri.

How could I retrive the main R3TR object of the ERROR ?

I've tryied quite all methods of cl_wb_object & cl_wb_object_type.

Thanks in advance for any help.

1 REPLY 1

Sandra_Rossi
Active Contributor
0 Kudos

Hi Taryck,

I never found ideal solutions, there are always exceptions. For instance, one of my code is (7.31/7.40):

    DATA: l_new_type_resolver_on TYPE boole_d.
    GET PARAMETER ID 'INTTYPE_RESOLVER_ON' FIELD l_new_type_resolver_on.
    SET PARAMETER ID 'INTTYPE_RESOLVER_ON' FIELD abap_true.
    wb_object = wb_object->get_main_object_ref( ).
    SET PARAMETER ID 'INTTYPE_RESOLVER_ON' FIELD l_new_type_resolver_on.
    wb_object->get_transport_key(
      IMPORTING
        p_object          = e071-object    " Object Type
        p_obj_name        = e071-obj_name  " Object Name in Object List
      EXCEPTIONS
        key_not_available = 1
    ).

Sandra