Code snippets will do wonders.
Pls show the code.
--
Krgrds,
Perry
System:
Vista/Office Ultimate
VS2005/VSTO2005 SE
>I am trying to port a VBA feature as a VBScript on a Web Page. I keep
>getting
> an "ActiveX object can't create object: 'Word.Application'. Is this a
> reference problem? How do you point the page to the where the Word
> reference
> is?
The intent is for this .htm file to sit on a share and for users to be able
to open documents on their machine. But how do you set the Word reference to
their computer?
...
dim wordApplication
set wordApplication = CreateObject("Word.Application")
wordApplication.Visible = True
dim gSourceWordDocument
'File1.value is the full path name to a .doc file
set gSourceWordDocument = wordApplication.Documents.Open(File1.value)
...
> Code snippets will do wonders.
> Pls show the code.
[quoted text clipped - 13 lines]
> > reference
> > is?
Perry - 17 Apr 2007 22:39 GMT
Do you want to open an .HTM file in IE using VBScript?
Why not navigate to the .HTM file then:
dim oExplorer
open_HTM
sub open_HTM()
Set oExplorer = Createobject("InternetExplorer.Application")
with oexplorer
.navigate "c:\AnyPath\test.htm"
...etc
--
Krgrds,
Perry
System:
Vista/Office Ultimate
VS2005/VSTO2005 SE
> The intent is for this .htm file to sit on a share and for users to be
> able
[quoted text clipped - 29 lines]
>> > reference
>> > is?
Perry - 17 Apr 2007 22:44 GMT
If you want to open in MS Word, the problem isn't yr code.
This should work.
If you save the VBScript as a VBS file and run it, does it come up with MS
Word and the document?
--
Krgrds,
Perry
System:
Vista/Office Ultimate
VS2005/VSTO2005 SE
> The intent is for this .htm file to sit on a share and for users to be
> able
[quoted text clipped - 29 lines]
>> > reference
>> > is?
George Lee - 20 Apr 2007 19:12 GMT
I stil get the same error message. But then again, the network share it's on
is not the same machine where the file is being opened at.
> If you want to open in MS Word, the problem isn't yr code.
> This should work.
[quoted text clipped - 43 lines]
> >> > reference
> >> > is?