MichaelB9860 Member since 2018 8 posts
Segue Technologies Inc
Posted: 6 months ago
Last activity: 6 months 2 weeks ago

Maintain carriage returns (in text area) or <p> tags (in Rich Text Editor) when using Word Templates

I am using Pega to generate some text which will be passed to a Word Template (currently text area control).

 SHAPE  \* MERGEFORMAT   Image removed.

When running the app, it looks like the following (I want the system to include the carriage returns):

  Image removed.               SHAPE  \* MERGEFORMAT

Before I call the word template (generate & print button), the system has the carriage returns in the clipboard:

 SHAPE  \* MERGEFORMAT   Image removed.



When the user clicks the Generate and Print button, the system calls a word template having the following field code {pega:reference.CommandersIntentStatement}

         SHAPE  \* MERGEFORMAT   Image removed.

When the system generates the Word document, it removes the carriage returns.

Image removed.

How can the system maintain the carriage returns?


I have also tried the Rich Text Editor (RTE), but that puts the <b>, <strong>, </strong>, and </b> tags in the word document.  Word doesn’t seem to know how to resolve the HTML tags.


Any help would be GREATLY appreciated.  Ideally we want to have the RTE functional, however, we would be ok with getting the “text area” working as well.


Pega Platform 8.3 Low-Code App Development Dev/Designer Studio System Architect
Share this page LinkedIn