I tried it, couldn't get it to work. Must be doing something wrong.
This is the code I put in:
Private Sub CommandButton1_Click()
With ActiveDocument
.SaveAs "[C:\Documents and Settings\HP_Owner\My Documents\Word]" &
.FormFields("ClientName").Result
For i = 1 To .FormFields.Count
.FormFields(i).Result = ""
Next i
End With
End Sub
Thanks
Malcolm
> Thanks a lot it looks great, I will try it.
>
[quoted text clipped - 30 lines]
> > >>
> > >> Eddie
Doug mentioned that you don't want the square brackets in the pathname.

Signature
Regards
Jonathan West - Word MVP
www.intelligentdocuments.co.uk
Please reply to the newsgroup
Keep your VBA code safe, sign the ClassicVB petition www.classicvb.org
>I tried it, couldn't get it to work. Must be doing something wrong.
> This is the code I put in:
[quoted text clipped - 50 lines]
>> > >>
>> > >> Eddie
Remove the square brackets [ ].
In my earlier post I wrote:
"You will need to replace the square brackets and the content within them"
that means:
REPLACE THE SQUARE BRACKETS
and
Replace the content within them

Signature
Hope this helps.
Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.
Doug Robbins - Word MVP
>I tried it, couldn't get it to work. Must be doing something wrong.
> This is the code I put in:
[quoted text clipped - 50 lines]
>> > >>
>> > >> Eddie
skateblade - 11 Nov 2005 21:41 GMT
Well, thanks again for your patience.
Sorry to be a pain. I tried and it gave me a run error
This is what I have now:
Private Sub savebutton_Click()
With ActiveDocument
.SaveAs "C:\Documents and Settings\HP_Owner\My Documents\Word" &
.FormFields("ClientName").Result
For i = 1 To .FormFields.Count
.FormFields(i).Result = ""
Next i
End With
End Sub
A box comes up and I get:
Run-time error '5941':
The requested member of the collection does not exist.
No idea what it means.
Obviously I'm missing something, nobody say a brain.
Thanks again Malcolm
> Remove the square brackets [ ].
>
[quoted text clipped - 64 lines]
> >> > >>
> >> > >> Eddie
Jonathan West - 11 Nov 2005 21:54 GMT
you need a closing backslash on the path.
.SaveAs "C:\Documents and Settings\HP_Owner\My Documents\Word\" _
& .FormFields("ClientName").Result

Signature
Regards
Jonathan West - Word MVP
www.intelligentdocuments.co.uk
Please reply to the newsgroup
Keep your VBA code safe, sign the ClassicVB petition www.classicvb.org
> Well, thanks again for your patience.
> Sorry to be a pain. I tried and it gave me a run error
[quoted text clipped - 88 lines]
>> >> > >>
>> >> > >> Eddie
skateblade - 11 Nov 2005 21:43 GMT
PS if anybody would like me to send the file to look at let me know.
Malcolm
> Remove the square brackets [ ].
>
[quoted text clipped - 64 lines]
> >> > >>
> >> > >> Eddie