You need to sign in to do that
Don't have an account?

Why do i get two error statements in my pageMessages
Hi all,
I've a Trigger and in that Trigger i've used addError method.
Everything is fine except i get two error statements like below, All i need is first line, i don't need second one..
Any suggestions?Please fill in Welcome Kit/ E-ID mailing address information
GT_taskCreation: execution of AfterUpdate caused by: System.DmlException: Update failed. First exception on row 0 with id a2nf000000075GmAAI; first error: FIELD_CUSTOM_VALIDATION_EXCEPTION, Please fill in Welcome Kit/ E-ID mailing address information: [] Trigger.GT_taskCreation: line 464, column 1 Trigger.GT_taskCreation: line 128, column 1
Thank you very much

I've a Trigger and in that Trigger i've used addError method.
Everything is fine except i get two error statements like below, All i need is first line, i don't need second one..
Any suggestions?Please fill in Welcome Kit/ E-ID mailing address information
GT_taskCreation: execution of AfterUpdate caused by: System.DmlException: Update failed. First exception on row 0 with id a2nf000000075GmAAI; first error: FIELD_CUSTOM_VALIDATION_EXCEPTION, Please fill in Welcome Kit/ E-ID mailing address information: [] Trigger.GT_taskCreation: line 464, column 1 Trigger.GT_taskCreation: line 128, column 1
Thank you very much
Can you share your VF code, Apex Class and Trigger code.
this issue occur normaly when you catch the exception and explictly set it' s message as the pageMessage via apex code. remove the code that explictly set the exception message as page message

I did override save() and finally now it works fine, Thanks all :)