I want to display an error message using apex trigger and display a list with bullets beside it, like

  • record name 1
  • record name 2

in the error message.

Is this possible with a trigger?

addError() is showing error only for one record, I want to display list of all.

  • Adding your existing code to your question will allow others to help more
    – Girbot
    Commented Jan 28, 2016 at 20:05

1 Answer 1


You could call addError()on each record, but that would give you multiple messages instead of the bullet list you want. There is an overloaded form of the addError method that can display your error with un-escaped markup though that might get you what you want. Basically, you could build up an html formatted string with all the content you want to display, then call addError(errString, false)


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .