Spire.Doc is a professional Word .NET library specifically designed for developers to create, read, write, convert and print Word document files. Get free and professional technical support for Spire.Doc for .NET, Java, Android, C++, Python.

Fri Apr 05, 2024 3:13 pm

Hi
how could i add separator line under my last parghraph's line like image below
Image
regards

XxLonely
 
Posts: 21
Joined: Sat Mar 30, 2024 5:11 pm

Sun Apr 07, 2024 2:49 am

Hi,

Thanks for your quesstion.
Sorry that I don’t see the image you provided, looks like the image’s corrupted. Could you provide a Word file that include the effect you wanted to help us find solution for you?

Sincerely
Abel
E-iceblue support team
User avatar

Abel.He
 
Posts: 1010
Joined: Tue Mar 08, 2022 2:02 am

Mon Apr 08, 2024 8:44 am

i added the photo in my drive then copy share link between image object i dont know why do photo corrupte
here is image another image in url obj
https://drive.google.com/file/d/1-l1bjSTJyxmj0oDO9sfD6bEsnZUWtNyf/view?usp=drive_link
here is word
https://docs.google.com/document/d/1gZrH7Mz05oAQUtQZRAvmWi-NiB5XUO0k/edit?usp=drive_link&ouid=102435116342937360489&rtpof=true&sd=true

XxLonely
 
Posts: 21
Joined: Sat Mar 30, 2024 5:11 pm

Tue Apr 09, 2024 6:16 am

Hi,

Thanks for your feedback.
According to the Word file, the under line of paragraph is the bottom border of paragraph, you can use the following code to set it for paragraph.
Code: Select all
#Create a new paragraph
paragraph = section.AddParagraph()

#Append Text
paragraph.AppendText("Hello World!")

#Set bottom border for paragraph
paragraph.Format.Borders.Bottom.BorderType = BorderStyle.Single


Sincerely
Abel
E-iceblue support team
User avatar

Abel.He
 
Posts: 1010
Joined: Tue Mar 08, 2022 2:02 am

Thu Apr 11, 2024 8:43 am

regards

XxLonely
 
Posts: 21
Joined: Sat Mar 30, 2024 5:11 pm

Return to Spire.Doc