0

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
    What have you already tried? – Alex Tennant Aug 6 '14 at 11:34
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

0

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

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.