469,917 Members | 1,891 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,917 developers. It's quick & easy.

Access to Word - Save Word document as

When I save a document in Word that I have transferred from VBA to
Word I notice that the "Save As" file name is for, instance, "December
4.doc". Since the date is the first field I print on the Word
document I guess it picks up this as a key.

How do I stipulate what the name of the document is to be once I want
to save it in Word?

" .SaveAs" actually saves the document and I want to view and edit the
document and manually save it.

It would be nice to have the document save as "C:\MyProgram\Documents"
& LastName & FirstName & Date & ".doc" .

Thanks
Nov 13 '05 #1
4 5593

"bborden" <bb*******@gmail.com> wrote in message
news:ea**************************@posting.google.c om...
When I save a document in Word that I have transferred from VBA to
Word I notice that the "Save As" file name is for, instance, "December
4.doc". Since the date is the first field I print on the Word
document I guess it picks up this as a key.

How do I stipulate what the name of the document is to be once I want
to save it in Word?

" .SaveAs" actually saves the document and I want to view and edit the
document and manually save it.

It would be nice to have the document save as "C:\MyProgram\Documents"
& LastName & FirstName & Date & ".doc" .

Thanks


Hi

Something like:
objWordDoc.SaveAs "C:\MyProgram\Documents\" & LastName & FirstName &
Format(Date, "d mmm yyyy") & ".doc"

Tip: use the macro recorder in Word to see how to carry out the actions you
are interested in.

Regards - Joe
Nov 13 '05 #2
Thanks Joe.

Nov 13 '05 #3
Thanks Joe.

Nov 13 '05 #4
The only problem in doing it your way is that the document will be
saved even if you elect not to save it. It actually saves a blank page.

Nov 13 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

4 posts views Thread by Jeff Harbin | last post: by
5 posts views Thread by ruomingxu via AccessMonster.com | last post: by
reply views Thread by Salome Sato | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.