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: 

/bobf/cl_frw_factory=>get_message with error Don´t Stop process?

ronaldo_aparecido
Contributor
0 Kudos

Hi experts.

I'm working with Determinations when i go SAVE data in NWBC.

I used a message error to validate duplicate data;

*------------------------------------------------------------

             lv_message-msgty = 'E'.

             lv_message-msgid = 'ZTM_BLOCK_NFE'.

             lv_message-msgno = '001'.

             IF eo_message IS NOT BOUND.

               eo_message = /bobf/cl_frw_factory=>get_message( ).

             ENDIF.

             eo_message->add_message(

               is_msg  = lv_message

               iv_node = is_ctx-node_key

               iv_key  = ls_key-key

                ).

*------------------------------------------------------------

This message is showed correctly in NWBC screen but don't stop the save process like se91 class messages.

I need to stop the save process when show this message error.

How can i Do it?

Thanks.

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi Ronaldo,

This should work if you also add your ls_key of the failed instance to the et_failed_key parameter of the determination.

However, if the duplicate data is coming from e.g. user input, so it is not caused by the determination itself, I would suggest to use an action validation on save instead of a determination.

Kind regards,

Bjorn

2 REPLIES 2

Former Member
0 Kudos

Hi Ronaldo,

This should work if you also add your ls_key of the failed instance to the et_failed_key parameter of the determination.

However, if the duplicate data is coming from e.g. user input, so it is not caused by the determination itself, I would suggest to use an action validation on save instead of a determination.

Kind regards,

Bjorn

0 Kudos

thanks.