We have added search box. Key in SAP issue keyword to search
TopBottom

Announcement: wanna exchange links? contact me at sapchatroom@gmail.com.

[sap-abap] error IF_ICCMP_CUCOBT_BOL_TRANS~SAVE (CL_ICCMP_CUCOBT_IMPL)

Posted by Admin at
Share this post:
Ma.gnolia DiggIt! Del.icio.us Yahoo Furl Technorati Reddit

Posted by crepmaster (Mr)
on Sep 19 at 6:26 PM
how can i avoid to catch an error in the method?
i have object where an attribute is not always define, i'm trying to test if that attribute it filled or not but an error occurs. in debugging , when the attribute is empty i noticed an error in the method IF_ICCMP_CUCOBT_BOL_TRANS~SAVE (CL_ICCMP_CUCOBT_IMPL) caught an error (code above)
CATCH cx_root INTO lr_exc.
* unspecific error
me->exception_handling( ir_exception = lr_exc ).
IF rv_success NE abap_true.
rv_success = abap_false.
lr_transaction->rollback( ).
lr_msg_service = cl_bsp_wd_message_service=>get_instance( ).
CALL METHOD lr_msg_service->add_message
EXPORTING
iv_msg_type = if_genil_message_container=>mt_error
iv_msg_id = lc_message_class
iv_msg_number = '005' " Unexpected error occurred during save
iv_msg_level = '1'.
ENDIF.
this the code i'm using
pr_activity_h = lr_entity->get_related_entity( iv_relation_name = 'BTHeaderActivityExt' ).
CHECK pr_activity_h IS BOUND.
*do not transfert activity with external serial number thqt start with *10 "C01
* CLEAR lv_description.
lv_description = pr_activity_h->get_property_as_string( iv_attr_name = 'EXTERN_ACT_ID' ). "C01
IF lv_description(2) = '10'.
pv_subrc = '4'. "C01
EXIT. "C01
ENDIF.
where do i make a mistake in my logic and code?
__.____._
Copyright © 2011 Toolbox.com and message author.

Toolbox.com 4343 N. Scottsdale Road Suite 280, Scottsdale, AZ 85251
View this online
  
Popular White Papers

In the Spotlight
Have you explored the Toolbox.com Marketplace? Learn more and access a free course now.

_.____.__

0 comments:

Post a Comment

T r a n s l a t e to your language