vla-GetInterfaceObject

vla-GetInterfaceObject

Anonymous
Not applicable
927 Views
4 Replies
Message 1 of 5

vla-GetInterfaceObject

Anonymous
Not applicable
I'm trying to call a method in my VS2005 DLL. It was working perfectly fine
until I had to format my drive and reinstall AutoCAD and Visual Studio 2005.
Nothing inside the code in either my Visual Lisp project or the DLL code.

Now, it fails on the vla-GetInterfaceObject call. Is there something I
forgot to install? I used to have VS2003 installed alongside VS2005 when
everything was working but i didn't bother reinstalling it.

Dale


Lisp code:

((member m_type bfld_mods)
(vl-load-com)
(setq $acad (vlax-get-acad-object))
(setq vbstrcls (vla-GetInterfaceObject $acad
"Elevations.BiFolds"))
(setq out (vlax-invoke-method
vbstrcls
"DrawBiFold"
$acad
fname
sc
(car mod_ins)
(cadr mod_ins)
(- unitID 1)
(gp:list->variantArray dim_list)
) ;_ end of vlax-invoke-method
) ;_ end of setq
out
)
0 Likes
928 Views
4 Replies
Replies (4)
Message 2 of 5

Anonymous
Not applicable
For some reason the 'Register for COM Interop" checkbox was a solid color
rather than displaying the usual check box. After clicking it a few times it
displayed the check box. Now the world is a happy place to be again.

Thanks anyway,

Dale

"Dale Levesque" wrote in message
news:5037793@discussion.autodesk.com...
I'm trying to call a method in my VS2005 DLL. It was working perfectly fine
until I had to format my drive and reinstall AutoCAD and Visual Studio 2005.
Nothing inside the code in either my Visual Lisp project or the DLL code.

Now, it fails on the vla-GetInterfaceObject call. Is there something I
forgot to install? I used to have VS2003 installed alongside VS2005 when
everything was working but i didn't bother reinstalling it.

Dale


Lisp code:

((member m_type bfld_mods)
(vl-load-com)
(setq $acad (vlax-get-acad-object))
(setq vbstrcls (vla-GetInterfaceObject $acad
"Elevations.BiFolds"))
(setq out (vlax-invoke-method
vbstrcls
"DrawBiFold"
$acad
fname
sc
(car mod_ins)
(cadr mod_ins)
(- unitID 1)
(gp:list->variantArray dim_list)
) ;_ end of vlax-invoke-method
) ;_ end of setq
out
)
0 Likes
Message 3 of 5

Anonymous
Not applicable
Did you register your assembly?
--
Bobby C. Jones
http://www.acadx.com

"Dale Levesque" wrote in message
news:5037793@discussion.autodesk.com...
I'm trying to call a method in my VS2005 DLL. It was working perfectly fine
until I had to format my drive and reinstall AutoCAD and Visual Studio 2005.
Nothing inside the code in either my Visual Lisp project or the DLL code.

Now, it fails on the vla-GetInterfaceObject call. Is there something I
forgot to install? I used to have VS2003 installed alongside VS2005 when
everything was working but i didn't bother reinstalling it.

Dale


Lisp code:

((member m_type bfld_mods)
(vl-load-com)
(setq $acad (vlax-get-acad-object))
(setq vbstrcls (vla-GetInterfaceObject $acad
"Elevations.BiFolds"))
(setq out (vlax-invoke-method
vbstrcls
"DrawBiFold"
$acad
fname
sc
(car mod_ins)
(cadr mod_ins)
(- unitID 1)
(gp:list->variantArray dim_list)
) ;_ end of vlax-invoke-method
) ;_ end of setq
out
)
0 Likes
Message 4 of 5

Anonymous
Not applicable
Hi Bobby. I'm actually using the "Start external program' method to run
AutoCAD so the assembly gets registered automatically (I'm assuming).

Dale



"Bobby C. Jones" wrote in message
news:5037801@discussion.autodesk.com...
Did you register your assembly?
--
Bobby C. Jones
http://www.acadx.com

"Dale Levesque" wrote in message
news:5037793@discussion.autodesk.com...
I'm trying to call a method in my VS2005 DLL. It was working perfectly fine
until I had to format my drive and reinstall AutoCAD and Visual Studio 2005.
Nothing inside the code in either my Visual Lisp project or the DLL code.

Now, it fails on the vla-GetInterfaceObject call. Is there something I
forgot to install? I used to have VS2003 installed alongside VS2005 when
everything was working but i didn't bother reinstalling it.

Dale


Lisp code:

((member m_type bfld_mods)
(vl-load-com)
(setq $acad (vlax-get-acad-object))
(setq vbstrcls (vla-GetInterfaceObject $acad
"Elevations.BiFolds"))
(setq out (vlax-invoke-method
vbstrcls
"DrawBiFold"
$acad
fname
sc
(car mod_ins)
(cadr mod_ins)
(- unitID 1)
(gp:list->variantArray dim_list)
) ;_ end of vlax-invoke-method
) ;_ end of setq
out
)
0 Likes
Message 5 of 5

Anonymous
Not applicable
Not unless you tell VS to do so. Which from your other post looks like you
have 🙂
--
Bobby C. Jones
http://www.acadx.com

"Dale Levesque" wrote in message
news:5037836@discussion.autodesk.com...
Hi Bobby. I'm actually using the "Start external program' method to run
AutoCAD so the assembly gets registered automatically (I'm assuming).

Dale



"Bobby C. Jones" wrote in message
news:5037801@discussion.autodesk.com...
Did you register your assembly?
--
Bobby C. Jones
http://www.acadx.com

"Dale Levesque" wrote in message
news:5037793@discussion.autodesk.com...
I'm trying to call a method in my VS2005 DLL. It was working perfectly fine
until I had to format my drive and reinstall AutoCAD and Visual Studio 2005.
Nothing inside the code in either my Visual Lisp project or the DLL code.

Now, it fails on the vla-GetInterfaceObject call. Is there something I
forgot to install? I used to have VS2003 installed alongside VS2005 when
everything was working but i didn't bother reinstalling it.

Dale


Lisp code:

((member m_type bfld_mods)
(vl-load-com)
(setq $acad (vlax-get-acad-object))
(setq vbstrcls (vla-GetInterfaceObject $acad
"Elevations.BiFolds"))
(setq out (vlax-invoke-method
vbstrcls
"DrawBiFold"
$acad
fname
sc
(car mod_ins)
(cadr mod_ins)
(- unitID 1)
(gp:list->variantArray dim_list)
) ;_ end of vlax-invoke-method
) ;_ end of setq
out
)
0 Likes