Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Open MSWord Template from Web Page

Status
Not open for further replies.

CAUFred

MIS
Mar 22, 2001
12
US
Newbe at Java script, can someone help me with this??????
I am trying to open a MSWord document template (as a new document) using a Java script in a local HTML page on my office file server. The problem is: 1.) a warning box about an "ActiveX control", 2.)Word will execute but minimized, 3.)Template will open but it is for editing the template, not as a new "Document".
This is the script that WILL open the template name passed in the 'strFile' var, ie. startWord("suppie.dot");

function startWord(strFile)
{
var myApp = new ActiveXObject("Word.Application")
var SubDirectory = "//tpd-cr1/tpdapps/forms/"
if (myApp != null)
{
myApp.Visible = true;
myApp.Documents.Open(SubDirectory + strFile)
}
}
Environment; Windows 95, IExplore 5.5, Office 97.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top