Hi @Athulya Pillai,
To convert files to PDF and upload them to SharePoint 2016, various methods and tools are available. You can consider the following options:
iTextSharp: iTextSharp is a popular open source library for programmatically creating and manipulating PDF files in .NET. You can use iTextSharp to convert files to PDF format in custom .NET applications. Once the conversion is complete, you can upload the PDF file to SharePoint 2016 utilizing SharePoint's Client Side Object Model (CSOM) or REST API
Power Automate: As mentioned earlier, you can leverage Power Automate to create workflows that automatically convert files to PDF and upload them to SharePoint 2016. You can use the available connectors and actions to perform the transformation and SharePoint upload steps. Power Automate provides a visual interface for designing workflows without coding.
The choice of method depends on your specific requirements, technical expertise and available resources. If you prefer a more customizable solution or have complex requirements, using iTextSharp or developing a custom application may be the best option.
Using the iTextSharp library in Visual Studio can be done as follows:Download the iTextSharp library:
You can download the latest version of iTextSharp from https://github.com/itext/itextsharp.
Extract the downloaded file.Create a new project or open an existing project in Visual Studio.
In Solution Explorer, right-click the project name and select Manage NuGet Packages.In the NuGet Package Manager window, click the Browse tab.
Type "itextsharp" in the search box and press Enter to search.Find the "iTextSharp" package in the search results, and click the "Install" button on the right to add the iTextSharp library to the project.
Here are some link about how to use iTextSharp to convert to PDF for your reference:
https://stackoverflow.com/questions/30197673/how-to-use-itextsharp-to-convert-to-pdf?rq=3
https://stackoverflow.com/questions/4471376/creation-of-pdf-file-using-itextsharp?rq=3
Here is a link about csom upload file to document library for your reference:
https://daoudisamir.com/from-c-to-sharepoint-file-upload-using-csom-with-subfolders-structure/
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.
Best Regards
Cheng Feng