Group: microsoft.public.word.vba.general
From: "Graham Mayor"
Date: Friday, March 21, 2008 6:34 AM
Subject: Re: How to let user know where to the attached Template is missing

You could add an autoopen macro to the document to attach the template in
question which will produce an error if it is not available

Sub AutoOpen
On Error GoTo ErrorHandler
ActiveDocument.AttachedTemplate = "C:\Program Files\Test.dot"
Exit Sub
ErrorHandler:
If Err.Number = 5180 Then
MsgBox "The document template is not available on this PC"
End If
End Sub

but there is no guarantee that the user will allow macros in documents to
run
A bit of user training might be more appropriate.

--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>



BJ wrote:
> I just want to make my prior questions a little bit clear.
>
> this template is used by the whole company not only one user. so it's
> not like i can tell this user what to do.
>
> they want to have a message remind them that they need to bring the
> template home for working on the document once they click on the doc
> instead of wondering why they didn't see all the tools they suppose
> to see. are there any ways that can let user know that. is that
> possible?
>
> "BJ" wrote:
>
>> user created a document using a template called test.dot which is
>> located at his office PC's C:\Program Files folder.
>>
>> user brings this document home and wantes to keep working on it, but
>> his home pc doesn't have this test.dot saved under his home pc's
>> C:\Program Folders. How can let user know that he doesn't have the
>> template and he needs to copy that to his home pc for keeping
>> working on this document.
>>
>> Thank you,