Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 08-19-2015, 06:19 AM
jbndylan jbndylan is offline How can I save a Word Document as a PDF file with a merged field filename? Windows 7 64bit How can I save a Word Document as a PDF file with a merged field filename? Office 2010 64bit
Novice
 
Join Date: Aug 2015
Location: Virginia, US
Posts: 1
jbndylan is on a distinguished road
Default

Hi, I get an "Compile error: Expected: end of statement" error on the save line.
dt = Format(CStr(Now), "mmddyyy")

ChangeFileOpenDirectory "\\vcuhshmo\groups\Claims Administration\CCU\PVOH\PVOH Mail Merge Letters\PVOH Mailers - Test\"

With ActiveDocument
' StrPath = .path & "\"
StrName = .Bookmarks("Name").Range.Text .SaveAs FileName:=StrName & ".docx"
End With
What have I missed?
Reply With Quote
Reply

Tags
merge field, save-as, word 2010



Similar Threads
Thread Thread Starter Forum Replies Last Post
Save merged document as concatenated merge field values texas791 Word VBA 4 02-25-2014 07:35 PM
How can I save a Word Document as a PDF file with a merged field filename? Macro to create new word doc and save the file using String found in the document VBNation Word VBA 2 02-08-2013 07:14 AM
How can I save a Word Document as a PDF file with a merged field filename? Auto update Filename field Oliver Beirne Word VBA 4 10-19-2012 03:33 AM
How can I save a Word Document as a PDF file with a merged field filename? Save Filename using Document Text Knawl Word 11 10-10-2011 03:00 AM
Word: The document 'Filename' caused a serious error the last time ... martincruise Word 0 02-25-2010 01:47 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 06:44 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft