You need to sign in to do that
Don't have an account?
csreddy7799
display page message on LICENSE_LIMIT_EXCEEDED
Hi,
I am creating user record using VF page and Apex class. When an Org does not contains sufficient user licenses of Type Salesforce, then I get following message.
But I want to display these message in customized way. For example, Message as "Your Org does not have sufficient Licenses"
System.DmlException: Insert failed. First exception on row 0; first error: LICENSE_LIMIT_EXCEEDED, License Limit Exceeded: []
Now i want display page message instad of exception. is it possible?
You can catch the DML error, inspect it and put your own error out.
Something like: