View Single Post
  #3  
Old 07-08-2009, 01:40 PM
mmcgregor mmcgregor is online now
Registered User
 
Join Date: 07-08-2009
Posts: 5
Question Availability of event prefix on WScript.CreateObject

That solves the control event problem nicely. Thanks for the quick response.

Just to follow up on the second related issue. WScript.CreateObject and the alias (also called event prefix) parameter. Is this/will this be available in VBPro 7.x? The prefix parameter, not avaialble in WScript presented through VBPro 6.7a, appears to be mandatory to make certain window event hooks happen; those that are not settable from the DOM (control OnClick() is, but OnQuit is not). Maybe I'm missing part of the DOM that allows this, but all posts that I've found solve this problem via the prefix parameter in the CreateObject call. The other alternatice that I've seen was WScript.ConnectObject(ieo, "ie_"), and this call is simply not available from within VBPro 7.

Thanks again for the information provided on the /mta switch!

Any thoughts on this issue would be appreciated. Thanks in advance!

Sample:
set ieo = WScript.CreateObject("InternetExplorer.Application ", "ie_")


sub ie_onQuit()
'Called when IE is closed
MsgBox("IE is closing")
end sub
Reply With Quote