Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Programming / March 2008

Tip: Looking for answers? Try searching our database.

How to let user know where to the attached Template is missing

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
BJ - 20 Mar 2008 20:55 GMT
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,
BJ - 20 Mar 2008 21:18 GMT
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?

> user created a document using a template called test.dot which is located at
> his office PC's C:\Program Files folder.
[quoted text clipped - 5 lines]
>
> Thank you,
Graham Mayor - 21 Mar 2008 12:34 GMT
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.

Signature

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

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

> I just want to make my prior questions a little bit clear.
>
[quoted text clipped - 17 lines]
>>
>> Thank you,
BJ - 24 Mar 2008 15:30 GMT
do you mean I need to show the users how to add the 'AutoOpen' macro to their
documents that they created using the template? can i distribute this macro
from the template? once the user opened the doc which has the template
attached to it, then 'copy' this code to the document?

> 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
[quoted text clipped - 34 lines]
> >>
> >> Thank you,
Graham Mayor - 24 Mar 2008 16:02 GMT
No, I meant the users need training to take home a copy of the template. I
also assumed that it was just one document and that could contain the macro,
albeit the user may not allow it to run. There is no real solution to this
other than the users having copies of the templates they wish to work with.

Signature

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

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

> do you mean I need to show the users how to add the 'AutoOpen' macro
> to their documents that they created using the template? can i
[quoted text clipped - 49 lines]
>>>>
>>>> Thank you,
BJ - 24 Mar 2008 20:42 GMT
under the Templates and Add-ins, the template name under 'Document template'
still contains the original template path, for example, "C:\Program
Files\Test.dot' even the template is not there.

are there any way i can get this using VBA?

I plan to put AutoOpen code under 'Normal' and to check the template name in
there, but don't want to show the not existing message to any other work docs
that are not using this template.

Thank you very much for your help.

> No, I meant the users need training to take home a copy of the template. I
> also assumed that it was just one document and that could contain the macro,
[quoted text clipped - 54 lines]
> >>>>
> >>>> Thank you,

Rate this thread:






 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.