1
votes

I'm running an old VB6 report. When I run it I get Run-time error '429': ActiveX component can't create object.

After clicking ok, I get: Error 2108: An error occurred while executing control script.

I've narrowed it down to in the .rpt object I'm getting the date with =Now(), the page number with ="Page " & rpt.txtPageNumber.DataValue & " of" (so it says "Page 1 of...").

These are Field objects in the report object with the "DataField" property set to those two scripts respectively.

I have tried registering any and all .ocx and .dll files that I have found on while looking for an answer online, but I don't know what file controls these specifically.

The other confusing thing is that in the same VB project I am calling these scripts on many reports in the exact same way, but this is the only report that throws the error. If I remove these scripts on the report, it will run without issue. I would appreciate any direction that anyone can give me.

If you would find any other information helpful to the issue, let me know and I will provide it.

1
Use SysInternals' Process Monitor. You'll see your program searching for a registry key in ...\Classes\CLSID\{guid} and not finding it. Document the {guid}. - Hans Passant
HKCU\Software\Classes\CLSID\{A2E6DDA0-06EF-4DF3-B7BD-5AA224BB06E8} - user1427105
c:\windows\system32\wiaaut.dll, the Windows Image Acquisition api. Specifically the support for images that were scanned. Tends to be a problem on XP. If that doesn't ring any bells then you haven't found the right one. - Hans Passant
That was it! Thank you for helping me through it. That .dll was not in the folder, so I copied it from elsewhere and registered it and was able to run the report. - user1427105

1 Answers

1
votes

wiaaut.dll was missing out of the System32 folder. I used Process Monitor to get the GUID that my application was looking for and tracked it back to this assembly.

Copying this assembly into the system folder and registering it with regsvr32 solved my problem.