Hi all,
Is there any way to load and control a hta file from within VBScript like
can be done for html?
This works for IE
Set objIE = CreateObject("InternetExplorer.Application")
objIE.navigate "file://c:\test.html"
objIE.left=200
objIE.top=200
objIE.height=225
objIE.width=440
objIE.menubar=0
objIE.toolbar=0
objIE.addressbar=0
objIE.statusbar=0
objIE.visible=1
etc, etc
What to do with *.hta so can load "do some work" then close the object?
Any help warmly appreciated,
Pete Gomersall

Re: Launch hta file from within vbscript by Walter

Walter
Tue Jun 13 16:37:00 CDT 2006

I'm not sure what can kind of control you're looking for. You can use
Shell.Run to launch a hta file along with arguments to control the window
parameters. The hta can close itself when it's finished via window.close().

"Pete Gomersall" <Pete.Gomersall@nau.edu> wrote in message
news:%23xeIZ3yjGHA.1204@TK2MSFTNGP02.phx.gbl...
> Hi all,
> Is there any way to load and control a hta file from within VBScript like
> can be done for html?
> This works for IE
> Set objIE = CreateObject("InternetExplorer.Application")
> objIE.navigate "file://c:\test.html"
> objIE.left=200
> objIE.top=200
> objIE.height=225
> objIE.width=440
> objIE.menubar=0
> objIE.toolbar=0
> objIE.addressbar=0
> objIE.statusbar=0
> objIE.visible=1
> etc, etc
> What to do with *.hta so can load "do some work" then close the object?
> Any help warmly appreciated,
> Pete Gomersall
>
>



Re: Launch hta file from within vbscript by Pete

Pete
Tue Jun 13 17:08:45 CDT 2006

Thanks for this but I need to be able to close the created hta application
object from the VBScript and the Shell.Run wouldn't provide this
functionality.
Pete

"Walter Zackery" <please_respond_to@group.com> wrote in message
news:GvKdnffLaKRhshLZnZ2dnUVZ_qCdnZ2d@comcast.com...
> I'm not sure what can kind of control you're looking for. You can use
> Shell.Run to launch a hta file along with arguments to control the window
> parameters. The hta can close itself when it's finished via
> window.close().
>
> "Pete Gomersall" <Pete.Gomersall@nau.edu> wrote in message
> news:%23xeIZ3yjGHA.1204@TK2MSFTNGP02.phx.gbl...
>> Hi all,
>> Is there any way to load and control a hta file from within VBScript like
>> can be done for html?
>> This works for IE
>> Set objIE = CreateObject("InternetExplorer.Application")
>> objIE.navigate "file://c:\test.html"
>> objIE.left=200
>> objIE.top=200
>> objIE.height=225
>> objIE.width=440
>> objIE.menubar=0
>> objIE.toolbar=0
>> objIE.addressbar=0
>> objIE.statusbar=0
>> objIE.visible=1
>> etc, etc
>> What to do with *.hta so can load "do some work" then close the object?
>> Any help warmly appreciated,
>> Pete Gomersall
>>
>>
>
>



Re: Launch hta file from within vbscript by mr_unreliable

mr_unreliable
Tue Jun 13 17:23:23 CDT 2006

Pete,

Take a look at the wshShell.Exec method.

That will start an app (say an hta) and return a
"wshScriptExec Object".

That object will allow you to keep track of the status
of the running object.

There is also a "terminate" method of the wshShellExec
object.

cheers, jw
____________________________________________________________

You got questions? WE GOT ANSWERS!!! ..(but,
no guarantee the answers will be applicable to the questions)




Pete Gomersall wrote:
> Hi all,
> Is there any way to load and control a hta file from within VBScript like
> can be done for html?
> This works for IE
> Set objIE = CreateObject("InternetExplorer.Application")
> objIE.navigate "file://c:\test.html"
> objIE.left=200
> objIE.top=200
> objIE.height=225
> objIE.width=440
> objIE.menubar=0
> objIE.toolbar=0
> objIE.addressbar=0
> objIE.statusbar=0
> objIE.visible=1
> etc, etc
> What to do with *.hta so can load "do some work" then close the object?
> Any help warmly appreciated,
> Pete Gomersall
>
>