1

Can anyone give me the code for copy rich text area content to Text area field after save. The text area should not contain any html tags in it.

1
  • 1
    What have you already tried? Commented Aug 6, 2014 at 11:34

2 Answers 2

1

I am not sure if it will help you, but I found the same question with answer here: How to copy data from Rich Text area field to Text Area field

1

As Paul already mentioned, there already is an answer to a similar question. However, if that doesn't answer your query, you might want to have a look at the stripHtmlTags() method in Salesforce.

Reference: stripHtmlTags()

But that will replace all the <br/> tags with a space. So consider replacing all your <br/> tags with a newline (/n) using the replaceAll() method

You must log in to answer this question.

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