Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Using .dot files over the Internet
Is there a way using client/server script or VBA to have a user click a
hyperlink to a .dot file stored on a web server and have a document created based on that template? I've tried script to automate Word from the server but get "ActiveX Component cannot create object" even with Word installed on the server. I'd prefer not to use client side script because of browser security setting dependencies, trusted site requirements or requiring an ActiveX component to be installed. It has to be simple and usable by a vast majority of regular users. Using IIS, I've ensured that the guest Internet account has rights on a virtual folder containing the .dot file, and enabled Write and even Script Source access in case some kind of extra permissions are required to launch an instance of the template. That doesn't work either. Heck, even choosing"Save As..." on a hyperlink to download a .dot file causes the file to be downloaded as a .doc file! I've even embedded an AutoExec macro in the .dot file: Sub AutoOpen() On Error Resume Next Dim objNewDoc As Word.Document Dim objOrigDoc As Word.Document Set objOrigDoc = Application.ActiveDocument Set objNewDoc = Documents.Add(Application.ActiveDocument.Name) Set objNewDoc = Nothing objOrigDoc.Close False Set objOrigDoc = Nothing End Sub What this does on a .dot file NOT stored in a web server is to force the creation of a document based on the opened .dot file and it then closes down the originally opened .dot file. However, on a web server this causes the ..dot file to be opened as Read Only and the macro doesn't run (even if Enable macros is clicked). Ideally the solution would not involve downloading the .dot file, and a new instance of the .dot file as a regular .doc file will be opened via the simple clicking of a hyperlinked .dot file stored in a web server. Any suggestions? -- Eric Legault (Outlook MVP, MCDBA, old school WOSA MCSD, B.A.) Try Picture Attachments Wizard for Outlook: http://www.collaborativeinnovations.ca Blog: http://blogs.officezealot.com/legault/ |
#2
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Using .dot files over the Internet
Hi Eric,
It takes a little 'passthrough' trickery http://support.microsoft.com/kb/278627/en-us?FR=1 ========= "Eric Legault [MVP - Outlook]" wrote in message ... Is there a way using client/server script or VBA to have a user click a hyperlink to a .dot file stored on a web server and have a document created based on that template? -- Let us know if this helped you, Bob Buckland ?:-) MS Office System Products MVP *Courtesy is not expensive and can pay big dividends Pricing and Packages for '2007 Microsoft Office System' http://microsoft.com/office/preview |
#3
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Using .dot files over the Internet
Thanks Bob. I've seen that article before and thought that would be
solution, however it only works when the client viewing the page containing the link has access to the file via a file system or UNC path. If the shortcut to the .dot file is created on a web server (for instance c:\InetPub\wwwroot\test\mytemplate.dot.lnk pointing to c:\InetPub\wwwroot\test\mytemplate.dot), then the shortcut will ONLY work on that web server, not on another PC trying to access the shortcut from http://webserver/test/mytemplate.dot.lnk. Eric "Bob Buckland ?:-)" wrote: Hi Eric, It takes a little 'passthrough' trickery http://support.microsoft.com/kb/278627/en-us?FR=1 ========= "Eric Legault [MVP - Outlook]" wrote in message ... Is there a way using client/server script or VBA to have a user click a hyperlink to a .dot file stored on a web server and have a document created based on that template? -- Let us know if this helped you, Bob Buckland ?:-) MS Office System Products MVP *Courtesy is not expensive and can pay big dividends Pricing and Packages for '2007 Microsoft Office System' http://microsoft.com/office/preview |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
document saved into temporary internet files | Microsoft Word Help | |||
word trys to open all files downloaded off the internet | Microsoft Word Help | |||
.ART files from internet | Page Layout | |||
How can I find a word document in Temporary Internet Files | Microsoft Word Help | |||
Double-click default for .dot files | Microsoft Word Help |