Use of legend
Add class text to status message dialog - so that the message will be changed dynamically