Skip to Content
avatar image
Former Member

Get Message

Hi all,

I want to get the message using the method GET_MESSAGES (Interface IF_WD_MESSAGE_MANAGER) inside a method of my web dynpro, but I have a problem with the type of returning parameter of method get_messages: TY_T_MESSAGES.

When I try to compile, I have this error: TY_T_MESSAGES is unknown.

How can I do for to solve?

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    Nov 04, 2009 at 03:27 AM

    Hi,

    The return paramater IS OF TYPE TY_T_MESSAGES .

    TY_T_MESSAGES os of type table TY_S_MESSAGES.

    TYPES :begin of ty_s_message,

    msg_index type i,

    element type ref to if_wd_context_element,

    attribute_name type string,

    err_message type string,

    msg_type type i,

    msg_object type ref to if_message,

    msg_user_data type ref to data,

    msg_parameter type wdr_name_value_list,

    is_permanent_msg type abap_bool,

    scope_permanent_msg type wdr_message_scope,

    controller_permanent_msg type ref to if_wd_controller,

    view type string,

    show_as_popup type abap_bool,

    attributes type string_table,

    is_validation_independent type abap_bool,

    msg_id type string,

    end of ty_s_message .

    types:ty_t_messages type standard table of ty_s_message with default key .

    Before you are passing the paramters to get_messages check the declaration of the variables used.

    Regards,

    Priya

    Add comment
    10|10000 characters needed characters exceeded

  • Nov 03, 2009 at 05:39 PM

    Hi,

    Have you declared all the local variables properly and passing to the method? I get a message when you do not do that.

    Regards

    Prasenjit

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 04, 2009 at 04:01 AM

    hi,

    When you call the method get_messages :

    • report message

    CALL METHOD lo_message_manager->get_messages

    receiving

    RESULT = lt_msgs.

    To check what type is supported by Result: Double click on get_messages -> Definiton -> select Mehod Get_messages -> Parameters -> See the type of Result - > Double click on ty_t_messages to knw the type of Result supported.

    Add comment
    10|10000 characters needed characters exceeded