For each Word document I have a matching Excel spreadsheet called, YYYY_Reunion.xlsx.
For example, I am doing a test of 10 out of 140 Word documentsĬalled, YYYY_Reunion.docx where 'YYYY' references a unique Class Year (i.e 1948, 1949, 1950.2014, 2015 2016). However, this time around I need to merge individual word documents with Excel spreadsheets. It seems, this automated project was such a success last year, I've been asked to repeat the process. ODoc.Close SaveChanges:=wdDoNotSaveChanges StrDocName = Left(strDocName, intPos - 1) Set oDoc = Documents.Open(strPath & strFilename) StrPath = Mid(strPath, 2, Len(strPath) - 2) If Right(strPath, 1) '\' Then strPath = strPath + '\'ĭocuments.Close SaveChanges:=wdPromptToSaveChanges MsgBox 'Cancelled By User',, 'List Folder Contents' Set fDialog = Application.FileDialog(msoFileDialogFolderPicker)
Is there anyway to convert or save (200+) Microsoft Word 2016 files on my PC to PDF? Or perhaps someone has written a macro or javascript that can process multiple Word files to do this repetitive task?Īfter trolling this site I found my answer here after doing a few minor tweaks: