VBA
Discuss AutoCAD ActiveX and VBA (Visual Basic for Applications) questions here.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

VBA load MS Control on Windows 64 bits

2 REPLIES 2
SOLVED
Reply
Message 1 of 3
diegoal
1454 Views, 2 Replies

VBA load MS Control on Windows 64 bits

Hello,

 

I am not able to use a MS control on my AutoCad 2015 64 bits (mscmoctl.ocx). I already registered the OCX control and loaded it in VBA / references 

In the other side, for instance, I am able to use it on Excel (see picture).

 

What should I do to add an OCX control to AutoCad VBA Ide?

 

Thanks,

 

 

 

 

---------------------------------------------------------------------------------------------------------
Diego Álvares
Civil Engineer @ Trento Engenharia Ltda.
www.trentoengenharia.com.br
Autocad Civil 3D 2010 to 2017 - Infrastructure Design Suite
Windows 7 64 i7 4770 @3.40GHz 8GB Ram GeForce GTX 760
Please use the Accept as Solution or Kudo buttons when appropriate
---------------------------------------------------------------------------------------------------------
2 REPLIES 2
Message 2 of 3
norman.yuan
in reply to: diegoal

You did not say, but judging from the picture you attached, your Excel (or your MS Office suite) is 32bit, while your VBA in AutoCAD 2015 is 64 bit.

 

You cannot use 32 bit ActiveX control in 64-bit process. You can tell from the piture you attached by the different items available in Excel and Acad2015's "add components" dialog box: there are much less items available in Acad 2015's 64bit VBA, only 64-bit controls are listed.

 

At this stage of ActiveX components, in terms of the technology's age, I would not expect there will be more 64-bit components available, which makes using AutoCAD's 64-bit VBA for a advanced development very difficult.

 

If you have to use the 32-bit controls, you either going bacl to AutoCAD 2013 or earlier: while you can still enjoy 64-bit AutoCAD itself, its VBA is 32 bit (thus runs very slow and with possible other issues); or you simply use 32-bit AutoCAD (still available for latest AutoCAD, 2015).

Norman Yuan

Drive CAD With Code

EESignature

Message 3 of 3
diegoal
in reply to: norman.yuan

Hello Norman,

 

I was postponing my VBA - Vb.Net code conversions but now, according your reply, I don't have alternatives 😕

 

Thanks for your reply.

---------------------------------------------------------------------------------------------------------
Diego Álvares
Civil Engineer @ Trento Engenharia Ltda.
www.trentoengenharia.com.br
Autocad Civil 3D 2010 to 2017 - Infrastructure Design Suite
Windows 7 64 i7 4770 @3.40GHz 8GB Ram GeForce GTX 760
Please use the Accept as Solution or Kudo buttons when appropriate
---------------------------------------------------------------------------------------------------------

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost