Skip to Content
author's profile photo
Former Member

Accessing the MessagePool

Hi,

i am looking for a way to access the Elements in the MessagePool of a Web Dynpro Component.

I only know that i can get the Text for a key with "wdComponentAPI.getTextAccessor().getText()"

What i want to do is to get the Amount of Elements inside the Messagepool. Can i get the Keys inside the Messagepool as a Stringarray or a Collection?

thanks for any advise

Regards,

Norbert

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

1 Answer

  • Best Answer
    author's profile photo
    Former Member
    Aug 09, 2004 at 02:30 PM

    Hi Norbert,

    you have to distinguish between the entries of the message pool you declare as text and the other types (standard, warning, error).

    The text entries are accessible the way you described, the other entries are accessible by IMessage<ComponentName>.CONSTANT (type WDMessage).

    For example if you declare a message with type "standard" and message key "NoEntry" in the component "Test", you'll get:

    IMessageTest.NO_ENTRY

    usable for example as

    wdComponentAPI.getMessageManager().reportMessage(IMessageTest.NO_ENTRY, null, false);

    In both cases there's no iterator, collection or array available.

    Hope that helps.

    Regards

    Stefan

    Add comment
    10|10000 characters needed characters exceeded