Error 800A01AD in VBScript on Windows Vista 64bit when create ActiveX object

1

I write script in VBScript for converting images. It use ImageMagic ActiveX. I write this script in Windows XP, it's run normaly, the same with Windows Vista 32bit, but in 64bit I have 800A01AD error when trying to create ActiveX object (both 32bit and 64bit have the same service pack installed)

Set imageMagick = CreateObject("ImageMagickObject.MagickImage.1")

I try to install ImageMagic as Admin (run as Administrator in Context Menu), I also try to run as Administrator:

regsvr32 wshom.ocx
regsvr32 scrrun.dll

with no success. And also try to run

regsvr32 ImageMagickObject.dll

Which run sucessfully but script still return error (the same as test script from ImageMagic)

jcubic

Posted 2011-01-19T16:19:43.293

Reputation: 1 533

Answers

1

Given that the script runs on two 32-bit machines but not on the 64-bit one, it seems like a 32/64bit problem.

A little background: a 64-bit process (Application) can not load 32-bit DLL/OCX etc. and a 32-bit process can not load 64-bit DLL/OCX etc. files.

I’m assuming that one of the following is happening:

1) You have installed the 64-bit version of ImageMagick and try to access it from the 32-bit Script environment.

2) You have installed the 32-bit version of ImageMagick and try to access it from the 64-bit Script environment. See this SO question for a solution for this scenario.

Tex Hex

Posted 2011-01-19T16:19:43.293

Reputation: 2 242