Visual LISP, AutoLISP and General Customization

Visual LISP, AutoLISP and General Customization

Reply
Valued Contributor
mrevelli
Posts: 84
Registered: ‎10-21-2003
Message 1 of 4 (80 Views)

CALL VB DLL FORM FROM LISP IN AUTOCAD 2006

80 Views, 3 Replies
06-23-2005 03:26 AM
Hi all ,
I need to call a form that is conpiled in a vb dll activeX from lisp in Autocad 2006 with this function:

(defun isq()
(vl-load-com)
(setq AcadObj nil)
(setq AcadObj (vlax-get-acad-object)
vbdll (vla-getinterfaceobject
AcadObj
"vbdll.ext"
)
)
(vlax-invoke vbdll "Show")
(vlax-release-object vbdll)
(vlax-release-object AcadObj)
(princ)
)

it works fine in Autocad 2005 while in Autocad 2006 it give me an error in line :
(vlax-invoke vbdll "Show")
"that cannot view form in this host application from a dll activeX or a property page".
Is there a 2006 bug ?
Any workaround.
Thanks in advance
Max
Distinguished Contributor
pciganek
Posts: 285
Registered: ‎01-08-2004
Message 2 of 4 (80 Views)

Re: CALL VB DLL FORM FROM LISP IN AUTOCAD 2006

06-24-2005 01:23 AM in reply to: mrevelli
Max,

I hope that this is not a bug in 2006 as I'll be upgrading soon - dragging a number of activex dlls with me from 2002.

What is your VB code for the show method? Are you calling your form as Modal or Modeless?

Peter
Valued Contributor
mrevelli
Posts: 84
Registered: ‎10-21-2003
Message 3 of 4 (80 Views)

Re: CALL VB DLL FORM FROM LISP IN AUTOCAD 2006

06-24-2005 04:46 AM in reply to: mrevelli
Hi Petersciganek ,

sub Show()
Form.Appearance = 1
Form.WindowState = vbNormal
Form.ProgressBar1.Value = 0
Form.Show vbModeless
end sub

It's indifferent in modal or in modeless
Thank's in advance
Max
Valued Contributor
mrevelli
Posts: 84
Registered: ‎10-21-2003
Message 4 of 4 (80 Views)

Re: CALL VB DLL FORM FROM LISP IN AUTOCAD 2006

06-28-2005 04:20 AM in reply to: mrevelli
Anyone have got this problem with Autocad 2006 ?
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Do you have 60 seconds to spare? The Autodesk Community Team is revamping our site ranking system and we want your feedback! Please click here to launch the 5 question survey. As always your input is greatly appreciated.