.NET

Reply
*Dale Levesque
Message 1 of 3 (125 Views)

Accessing Global Lisp variable within Dot Net DLL

125 Views, 2 Replies
10-19-2005 11:03 AM
I use the following code to call a sub in a dot net DLL. Is there a way to
access the value of a global Lisp variable? I don't want to save it to
"users" if i don't have to.

(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
(car mod_ins)
(cadr mod_ins)
(- unitID 1)
) ;_ end of vlax-invoke-method
) ;_ end of setq
out
(vlax-release-object vbstrcls)
(vlax-release-object $acad

Dale
*Tony Tanzillo
Message 2 of 3 (125 Views)

Re: Accessing Global Lisp variable within Dot Net DLL

10-19-2005 01:55 PM in reply to: *Dale Levesque
If you are calling a function in a COM server you wrote,
why not pass the value of the global LISP var to the
method as a parameter?

--
http://www.caddzone.com

AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006
http://www.acadxtabs.com

"Dale Levesque" wrote in message news:4989132@discussion.autodesk.com...
I use the following code to call a sub in a dot net DLL. Is there a way to
access the value of a global Lisp variable? I don't want to save it to
"users" if i don't have to.

(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
(car mod_ins)
(cadr mod_ins)
(- unitID 1)
) ;_ end of vlax-invoke-method
) ;_ end of setq
out
(vlax-release-object vbstrcls)
(vlax-release-object $acad

Dale
*Dale Levesque
Message 3 of 3 (125 Views)

Re: Accessing Global Lisp variable within Dot Net DLL

10-19-2005 01:59 PM in reply to: *Dale Levesque
ROFL. That was bad. As you can see, I'm already passing several variables
already. What a brain burp.

Thanks Tony.

"Tony Tanzillo" wrote in message
news:4989405@discussion.autodesk.com...
If you are calling a function in a COM server you wrote,
why not pass the value of the global LISP var to the
method as a parameter?

--
http://www.caddzone.com

AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006
http://www.acadxtabs.com

"Dale Levesque" wrote in message
news:4989132@discussion.autodesk.com...
I use the following code to call a sub in a dot net DLL. Is there a way to
access the value of a global Lisp variable? I don't want to save it to
"users" if i don't have to.

(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
(car mod_ins)
(cadr mod_ins)
(- unitID 1)
) ;_ end of vlax-invoke-method
) ;_ end of setq
out
(vlax-release-object vbstrcls)
(vlax-release-object $acad

Dale
Announcements
Are you familiar with the Autodesk Expert Elites? The Expert Elite program is made up of customers that help other customers by sharing knowledge and exemplifying an engaging style of collaboration. To learn more, please visit our Expert Elite website.
Need installation help?

Start with some of our most frequented solutions or visit the Installation and Licensing Forum to get help installing your software.