Bobby
Sat Apr 16 05:50:01 CDT 2005
ok thanks for that, but i now have doing what i want to do but my only
problemis is now that it keeps trying to save to "my documents" instead of
the network drive where it was opened, do you know how i can keep the
original path?
"Jean-Guy Marcil" wrote:
> Bobby was telling us:
> Bobby nous racontait que :
>
> > I've been trying to save a ducument from a macro as follows
> > Private Sub CommandButton1_Click()
> > With Dialogs(wdDialogFileSaveAs)
> > .Name = Format(Date, "dd mmm yyyy") & (" t-l information and
> > handover050411.doc")
> > .Show
> > End With
> >
> > End Sub
> > problem is that we access the original file from a short cut and when
> > the file is backed up it obviously puts the date at the front and
> > changes the name. problem is the shortcut we use then takes us back
> > to the unsaved document of the original name. Can anyone help please?
>
> This is normal behaviour. The shortcut points to a file, when you run your
> macro, you create a new file.
> You would have to edit the shortcut and I am not sure if you can do that
> from within Word (Shortcut properties are possibly accessible via
> scripting.)
>
> Or you could have code that creates a document variable in the original
> document when you create the backup. Then, when the original document is
> opened, users could be given a message box to remind them that a newer
> version exists.
> You could even ask them if they would like to automatically open it if they
> click Yes, providing that it was not moved since having been created...
>
> --
> Salut!
> _______________________________________
> Jean-Guy Marcil - Word MVP
> jmarcilREMOVE@CAPSsympatico.caTHISTOO
> Word MVP site:
http://www.word.mvps.org
>
>
>
>