cancel
Showing results for 
Search instead for 
Did you mean: 

Messages in webdynpro abap

Former Member
0 Kudos

hi all,

can any one help me by provinding me with a small example on how to implement messages in a webdynpro application.

Thanks in advance,

chandana.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

refer to these examples

DEMO_MESSAGEs,WDR_MESSAGE_AREA,WDR_TEST_MESSAGE_AREA

Answers (4)

Answers (4)

srinivasarao_kambala4
Active Participant
0 Kudos
Former Member
0 Kudos

Hi,

Use the IF_WD_MESSAGE_MANAGER interface .

All messages will be displayed in a dedicated message area.

By default the message area appears at the top of the page.

The message are can be moved like a UI element in a view. You find a UI element (Message Area) in the UI library Pattern. Messages will be placed in this area, if it is available.

Use the WD code wizard to create the required coding to report a message. (Generate Message radio button)

Generated/sample code will look like this.....

..
   * get message manager
data: l_current_controller type ref to if_wd_controller,
      l_message_manager    type ref to if_wd_message_manager.

l_current_controller ?= wd_This->Wd_Get_Api( ).

CALL METHOD l_current_controller->GET_MESSAGE_MANAGER
  RECEIVING
    MESSAGE_MANAGER = l_message_manager

  * report message
CALL METHOD l_message_manager->REPORT_ATTRIBUTE_ERROR_MESSAGE
  EXPORTING
    MESSAGE_TEXT   = 'REPORT_ATTRIBUTE_ERROR_MESSAGE'
    ELEMENT        = Elem_Flights
    ATTRIBUTE_NAME = 'CITYFROM'. 

-

Achyut

Former Member
0 Kudos

Hi,

Messages are reported using methods of IF_WD_MESSAGE_MANAGER. By using the REPORT_ATTRIBUTE_* methods, you can link a message to a specific input field, which will be highlighted on the view.

Go through the below links.

[https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/63a47dd9-0b01-0010-3d8e-de27242bf011] -> Messages

Hope this will help.

Thanks.

Former Member
0 Kudos

Hi chandana

Also please refer this example

WDR_TEST_DOCU

and select long text option.

There u can find messages in wd4a.

Cheers,

Mary

Former Member
0 Kudos

hi chandana,

Go through these predefined applications in webdynpro u will get a better idea.

WDR_TEST_MSG_AREA and WDR_TEST_INPUT

Also go through following link

http://help.sap.com/saphelp_nw2004s/helpdata/en/d8/2a934259a5cb6ae10000000a155106/frameset.htm