my problem is in word document some word in bold format and deferent style,
when i get this text in string variable then in not come in original format. it shows plane text.
how to solve this problem?
for exmlple:
๐๐ก๐ข๐ฌ is ๐๐จ๐ โ original text
This is a Dog โ in message box result
When you retrieve text from a Word document into a string variable, the formatting information isnโt directly preserved in the string variable because a plain string variable canโt store formatting information.
You can use copy and paste directly from a formatted Word document to preserve the format.
Hi @AJ_Ask
my use case is i have template in word. which is in paragraph.
adding some condition in want to mail paragraph condition wise.
for example
1=โVinayakโ then send this paragraph on mailโฆ
but when i send email, then text is plane not bold and other style
Use a Word file with HTML tags as the input for the email body which will preserve the formatting in UiPath:
Read Word File:
Utilize the โRead Text Fileโ or โRead Word Fileโ activity to read the content of your Word file into a variable.
Send Email:
Choose an email activity (e.g., โSend Outlook Mail Messageโ).
Set the variable containing Word file content as the body of the email.
Ensure the email activity supports HTML formatting, and set the IsBodyHtml property to True.
It is the same for me. Since youโre using it as a template, you can also go with storing the content in HTML format and use it to as a mail body. It will surely get your desired formatting.