Saving as .rtf

L

Lee

I am trying to code my Word Templates so that the SaveAs
Dialog box goes to the correct folder and shows only .rtf
files... So far I have the following code but it does not
show only .rtf files, it only shows .doc files... Arrgghh!!

'Set the initial path to the M:\ drive and Save.

Dim fd As FileDialog
Set fd = Application.FileDialog(msoFileDialogSaveAs)
With fd
.InitialFileName = "M:\usinput\comserv\*.rtf"
.Show
End With

Unfortunately, our electronic filing program uses
only .rtf documents so users need to be prompted to save
as .rtf... Cheers
 
J

Jay Freedman

Hi, Lee,

Try it this way:

With Dialogs(wdDialogFileSaveAs)
.Name = "M:\usinput\comserv\*.rtf"
.Format = wdFormatRTF
.Show
End With
 
L

Lee

Hi Jay

Thanks for that... The .Format = wdFormatRTF part works
but now it will not automatically go to the folder
M:\usinput\comserv\

Lee
 
L

Lee

I've finally got it...

Played around with your code Jay and it works now...

With Dialogs(wdDialogFileSaveAs)
.Name = "M:\usinput\comserv\"
.Format = wdFormatRTF
.Show
End With

Had to take out the *.rtf part from .Name.. Cheers
Lee
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top