Word to PDF Batch Conversion

I needed to convert a bunch of Word files to pdf. I found this visual basic code that basically opens all files one after another in Word and saves a pdf version.

'Convert .doc or .docx to .pdf files via Send To menu
Set fso = CreateObject("Scripting.FileSystemObject")
For i= 0 To WScript.Arguments.Count -1
   docPath = WScript.Arguments(i)
   docPath = fso.GetAbsolutePathName(docPath)
   If LCase(Right(docPath, 4)) = ".doc" Or LCase(Right(docPath, 5)) = ".docx" Then
      Set objWord = CreateObject("Word.Application")
      pdfPath = fso.GetParentFolderName(docPath) & "\" & _
	fso.GetBaseName(docpath) & ".pdf"
      objWord.Visible = False
      Set objDoc = objWord.documents.open(docPath)
      objDoc.saveas pdfPath, 17
      objDoc.Close
      objWord.Quit   
   End If   
Next
vbs file

Just save it as a vbs somewhere and add a ahortcut to the context menu.

C:\Users\%username%\AppData\Roaming\Microsoft\Windows\SendTo
Context Menu Entry

You can select multiple files at once and they get converted one by one.

Simple manual Backup with robocopy

I wanted to have a “simple” solution for an (external) backup of my USB stick. The simplest way would be copy and paste, but I wanted something more robust. So what gets you robust copying of files in Windows? Robust File Copy – robocopy –, of course.

I use this manually, but for internal or permanently attached drives etc. this could be automated with task planning and removing the user promts.

Continue reading “Simple manual Backup with robocopy”

Creating individual files from MS Word form letters (Update)

tl;dr: Use pdfsam

MS Word has a good form letter feature, but it’s limited in a way: when you want to save each form letter individually, you’re out of luck. You can only create a single Word document, which contains all letters. I was searching far and wide for a solution to my problem and stumbled upon some Add-ins, but what helped me the most is a simple macro.

Continue reading “Creating individual files from MS Word form letters (Update)”