Skip to Content
author's profile photo Former Member
Former Member

Message Area problems

I have a view with a tree on the left, a details view on the top right, and a reference table on the bottom right. As you can guess, there are many cases where I need to display info or error messages to the user and would like to have the messages appear below the particular view that caused the problem. I also use modal dialogs on this page and would like to use messages on it as well (and have the messages appear on the dialogs themselves).

Due to the logic the MessageManager uses to determine where to display messages, I can't control the enabled/visible properties of my MessageAreas at runtime because they only actually display messages if they are bound to read-only context attributes.

How can I use multiple MessageAreas on one screen?

-Dave

Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on May 25, 2005 at 10:45 PM

    Hi

    Well i guess you have 3 viewsets if i am not wrong.Even if it is 2 viewsets its fine. Say one contains the Tree element in the left View and the right hand side contain 2 other views say table and form.

    Define explicit message areas on each of the views.

    Well before that the thing you will have to do is create a boolean context attribute in the view context and have the read-only property of that attribute to true.

    Then bind this attribute to the enabled property of the explicit message areas defined in the views. When you want to display messages in the Left view enable the message area at runtime.

    When you want to display messages in the Table View enable that message area and disable the remaining message areas. Do this as per your requirement.

    This is the only way you can do it. We are doing it for multiple popups and it works.The maximum popups we have in our scenario is upto 3 levels. So i guess for any level of popups we should be able to display the messages in that respective window in this way.

    let me know if that helps you.

    regards

    ravi

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      The read-only property of a context attribute means that this attribute may not be changed by the client.

      See Javadoc for IWDAttribute:

      isReadOnly

      public boolean isReadOnly()

      Checks whether this attribute is read only <b>for clients</b>.

      Note: if an attribute is read-only for clients, it might or might not be writable for applications. Normally all attributes are writable for applications, but if a context attribute is mapped to a model class property and if that model class property is read-only or if the attribute is calculated and no setter is declared, then the attribute is read-only for applications, too.

      Returns:

      read only state of attribute

      Armin

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.