Activity Forums Salesforce® Discussions Why we used severity and strength in <apex:pageMessage> in Salesforce?

  • Why we used severity and strength in <apex:pageMessage> in Salesforce?

    Posted by Pooja on January 21, 2020 at 1:54 pm

    Why we used severity and strength in <apex:pageMessage> in Salesforce?

    Ratnesh replied 4 years, 2 months ago 3 Members · 2 Replies
  • 2 Replies
  • Shweta

    Member
    January 21, 2020 at 2:23 pm

    apex:pageMessage : It  is used to display a  custom message in the page using the Salesforce formatting.

    ex : <apex:pageMessage summary="Hello" severity="info" strength="3" />  And

    Severity is used for control the display of the message box.

    Strength is used for controls the visibility and size of the message box.

  • Ratnesh

    Member
    January 21, 2020 at 5:25 pm

    Hey Pooja,

    <apex:pagemessage> is a tag in visualforce which used to show the message on the page.

    Severity:- It basically denotes the type of message like to show warning, error, info and confirm with an icon.

    Strength:- It basically denotes with the size{o-3}.  Higher the size icon will larger and vice-versa.

    Example:-  <apex:pagemessage summary="Pooja your message will be here" severity="info" strength="3"></apex:pagemessage>

     

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos