VBA fails with Run-time Error 429 "ActiveX component can't create object"



XL 2007

Source File: MathNet.dll
Output file: MathNet.tlb

Included Classes MathNet.Division and MathNet.Multiplication
Functions DivideBy4(), DivideBy2(), MultiplyBy2(), MultiplyBy4()

After Visual Studio created a Visual Basic DLL (MathNet.dll) and (MathNet.tlb)
In Excel VBA IDE I entered the following code:

Sub TestDLL()

Dim Result As String
Dim MF As MathNET.Division 'Intellisense does display "Division"
Set MF = New MathNET.Division 'Fails w/Run-time Error 429 ActiveX component can't create object
Result = MF.DivideBy4(1234) 'Intellisense does display "DivideBy4"

End Sub

Need help to overcome the ActiveX error

Do I need to add a referrence? If not "Registered" how to do it?

TIA EagleOne




You need to add the MathNet.Dll and MathNet.tlb to the VBA references. go to
VBA menu tools - References and select browse. The window will automatically
be set for TLB and DLL file types.

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question