Monday 10 February 2014

How to remove required field validation in a Visualforce page?


To remove required field validation in a Visualforce page, set immediate attribute in <apex:commandButton> to true.

Example:

            <apex:commandButton value="Cancel" action="{!cancl}" immediate="true"/>

here immediate="true" makes the action to be executed first before executing any validation rule.

No comments:

Post a Comment