cancel
Showing results for 
Search instead for 
Did you mean: 

Error Message

Former Member
0 Kudos

Hi,

I have a req in Webdynpro standard view to display error message when field have no value.

For this i have used enhancement and under that i am displaying error msg by

CALL METHOD cl_dp_wd_msghdl=>report_message

EXPORTING

iv_message = lv_message

  • iv_show_as_popup = ABAP_FALSE

iv_cancel_navigation = 'X'" ABAP_TRUE

io_api_controller = lr_controller

iv_message_type = 'E'

io_fpm_msg_manager =

wd_comp_controller->mo_fpm->mo_message_manager.

but it is stoping there ?

saved the order with sucess message and error message both.

Accepted Solutions (0)

Answers (2)

Answers (2)

former_member199125
Active Contributor
0 Kudos

Shilpi,

Use report_error_message...

report mesage will simply show the message, it wont stop the process. where as report_error_message will stop the process.

Regards

Srinivas

Former Member
0 Kudos

it is still not stopping plez send me alternative solution.

former_member199125
Active Contributor
0 Kudos

hi..

pls post ur code, so that i can change. or follow this way...

***ls_value is field value

IF LS_value IS INITIAL.

  • report message

CALL METHOD LO_MESSAGE_MANAGER->REPORT_ERROR_MESSAGE

EXPORTING

MESSAGE_TEXT = 'Please enter the value.'

  • PARAMS =

  • MSG_USER_DATA =

  • IS_PERMANENT = ABAP_FALSE

  • SCOPE_PERMANENT_MSG = CO_MSG_SCOPE_CONTROLLER

  • VIEW =

  • SHOW_AS_POPUP =

  • CONTROLLER_PERMANENT_MSG =

  • MSG_INDEX =

  • CANCEL_NAVIGATION =

  • RECEIVING

  • MESSAGE_ID =

.

else.

here write your actual logic, i mean if value is there ..

Endif.

Regards

Srinivas

Former Member
0 Kudos

Hi,

I have done like this .

this is enhancement in webdynpro.

CALL METHOD lr_controller->get_message_manager

RECEIVING

message_manager = lo_message_manager.

CALL METHOD lo_message_manager->report_error_message

EXPORTING

message_text = lv_message

show_as_popup = 'X'"iv_show_as_popup

cancel_navigation = abap_true "iv_cancel_navigation

view = 'V_ADD_DATA'.

former_member199125
Active Contributor
0 Kudos

Shilpi,

Use report_error_message...

report mesage will simply show the message, it wont stop the process. where as report_error_message will stop the process.

Regards

Srinivas