Skip to Content
avatar image
Former Member

Reusing Messages (Message Pool)


I am making some experiments with message pool.

Is it possible to reuse messages? Is it related with components reuse?


Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Aug 18, 2004 at 03:38 PM

    Hi Ronaldo,

    yes, if you have added the component usage of Component A to component B the message pool (IMessageXXX interface) of A is known by B, you can access it by

    wdComponentAPI.getMessageManager().reportMessage(IMessageA.ERROR_MESSAGE, null, false);

    for example.


    Sorry i've forgotten temporarily:

    This is not possible this way, since the calling component cannot access the message texts in the resource bundles of the defining component. You must get access to the IWDMessageManager instance of the component which has defined the message (maybe by exposing the message manager of A in a method getExtMessageManager() of the interface controller of A).

    So the call would look like

      reportMessage(IMessageA.ERROR_MESSAGE, null, false);

    Hope that helps.



    Add comment
    10|10000 characters needed characters exceeded