User:Thinktechlabs

=Display messages on Visualforce Page=

To display messages on VF pages add these statements in the Apex class.

 * 1) To show info messages :ApexPages.addMessage(new ApexPages.Message(ApexPages.Severity.INFO, 'Some info message'));
 * 2) To show error messages:ApexPages.addMessage(new ApexPages.Message(ApexPages.Severity.ERROR, 'Some error message'));
 * 3) To show warning messages:ApexPages.addMessage(new ApexPages.Message(ApexPages.Severity.FATAL, 'Some error message'));

Showing messages directly on the VF page:
