Hi
I'm running MC 18 (195) on Windows 8 x64.
I'm intending to use WSH/VBS to build a simple script that will write an XML file to disk when a track on MC changes.
I haven't got into the event triggers yet - just trying to interact with MC18.
I'm using the following:
----
On Error Resume Next
Set mc = GetObject(, "MediaJukebox Application")
If Err.Number = 429 Then
on error goto 0
Set mc = CreateObject("MediaJukebox Application")
End If
wscript.echo mc.ispurchased()
set mcz = mc.GetZones()
set mz = mcz.getzone(0)
wscript.echo mz.GetName()
----
I run the script from the Admin CMD window, and have also tried the SYSWOW64 CMD window run by the administrator, and get the same results.
The script seems to work fine when MC is not running.
But if I manually start MC then the script fails.
The CreateObject function seems to maximize any MC window but then hangs until it times out with the error:
>>>(5, 4) Microsoft VBScript runtime error: ActiveX component can't create object: 'MediaJukebox Application'
Any suggestions gratefully appreciated.
David