Remove Borders in Word with NET REST API

This article guides how to remove borders in Word with NET REST API. You will learn to automatically remove paragraph border in Word with C# REST API using the .NET cloud SDK. We will learn the process to remove individual or all the borders from a paragraph.

Prerequisite

Steps to Remove a Border in Word with C# Low Code API

  1. Initialize the WordsApi object by setting the cloned ID and secret to remove paragraph borders
  2. Create an object of the DeleteBordersOnlineRequest class for removing all borders
  3. Read the input Word file into the memory stream for deleting a border
  4. Set the destination file name, node path, and document binary stream in the request object
  5. Call the DeleteBordersOnline() method to remove the borders
  6. Save the output stream to a file from the API response object

The above steps summarize how to remove border in Word with C# Low Code API. Create an object of the WordsApi class, create a DeleteBordersOnlineRequest object, and set its properties. Invoke the DeleteBordersOnline() method to delete the border.

Code to Remove Paragraph Border in Word with C# REST API

This sample code exhibits how to remove a border in Word with NET REST API. When we call the DeleteBordersOnline() we do not need to set the border type value. However, if you want to delete a particular border, use the DeleteBorderOnline() method and set the border type in the request object.

We have learned to remove borders from the paragraphs. To add a border to a paragraph, refer to the following article: Add a Border to a Word Document with NET REST API.

 English