How do I display a custom message in webtop like the one that shows when you import a document? (The sliding green or red rectangle that shows up on the bottom of the screen).
Look in the WDK Development Guide for Message Bar component
To show error messages you can use the ErrorMessageService class.
If I remember, the syntax is ErrorMessageService.getService().setNonFatalError.
It will show a red message.
For common messages you can use MessageService.
So the following works and does display the sliding red notification:
ErrorMessageService.getService().setNonFatalError(this, "MSG_TIERS_NOT_FOUND", null);
However it also shows a popupu with the same error. I only need the sliding error.
Anyway around this?
Hi,
To display message only in status bar --> MessageService.addMessage(this, "MSG_TIERS_NOT_FOUND");
To display message in message list --> MessageService.addDetailedMessage(this, "MSG_TIERS_NOT_FOUND",..);
To display detailed error message --> ErrorMessageService.getService().setNonFatalError(this, "MSG_TIERS_NOT_FOUND", null);
-Siva
Thanks Siva, this does what I want. Except it's green and it should be red.
But to my knowledge status bar displays messages in one color only. You can customize the status bar css to change the color to Balck or Blue irrespective of messages.