Underline/bold text in string to create word/pdf document

Hello,

I need to create a PDF with a Text which includes different format.

Therefore I created a string with Assign-Activity
Textblock = "text + environment.newLine + “other text”

After that i create a word document and insert my Textblock, and save that as PDF

Can I change the format of parts of my Textblock anyhow?

When I use html I would use “< b >< /b >” etc., but that didn’t work when I insert the text in a word document.

Do you have an idea how to handle it?

Otherwise I can try to work with an Excel-template and fill in my different strings

Best regards,
Thomas

@thomas.seeber

So you want a new line automalically at some specific place?

if so for word…you can try to have a dummy tag in those areas and replace that tag with new line character

cheers