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/ |
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 |