Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Convert Word Documents to PDF using PowerShell script

Install

Open a PowerShell terminal and clone the repository:

git clone https://github.com/diversen7/doc_to_pdf.git
cd doc_to_pdf

Convert using Windows paths

.\Convert-DocToPdf.ps1 -InputPath "C:\Users\azks430\doc_to_pdf\sample1.docx" -OutputPath "C:\Users\azks430\doc_to_pdf\sample1.pdf"

Convert using WSL Paths

.\Convert-DocToPdf.ps1 -InputPath "\\wsl$\Ubuntu\home\dennis\digiarch\tmp\CC69HP9P.doc" -OutputPath "\\wsl$\Ubuntu\home\dennis\digiarch\tmp\CC69HP9P.doc.pdf"

Convert multiple files

This will convert all .docx, doc files in the input directory to PDF and save them in the output directory. The output directory will get the same structure as the input directory.

.\Convert-DocToPdf-dirs.ps1 -InputDir .\input -OutputDir .\output

About

Convert e.g. .docx or .doc to .pdf

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages