What about stand alone development, outside Civil 3D?
Is it possbible to reference C3D dot net libraries in stand alone devlopments?
Or should developers only build applications to worlk inside C3D?
Are the answers consistant with 2012 and 2013 versions of C3D?
I disagree with everyone who thinks LISP is old and a bad way to develop Civil 3D.
LISP is cool, clear, and stable, and one can do a lot of things using LISP.
The key is to know how to use properties and methods, and just all of then use the same structure :
(vlax-get-Property *Object* 'Property)
(vlax-inoke-method *Object* 'Method)
Although to start a Civil 3D application, we need to know some other functions
First of all we activate the Visual Lisp extension for AutoLISP
(vl-load-com) ;;;Enables vl, vla and vlax funtions
To catch the Civil 3D application (an objet of AeccAplication class)
(if (not *Civil3D*)
(vlax-get-acad-object);;;AutoCAD Object Application (any version)
"AeccXUiLand.AeccApplication.7.0" ;Civil3D2010 Object Application
) ;;;some other versions:
) ;;; 2009... "AeccXUiLand.AeccApplication.6.0"
) ;;; 2011... "AeccXUiLand.AeccApplication.8.0"
;;; 2012... "AeccXUiLand.AeccApplication.9.0"
From here, we can use properties and methods as if we were using any other language:
For example, to take the ActiveDoument (a AeccApplication Property)
(if (not *aeccDoc*)
(setq *aeccDoc* (vlax-get-Property *Civil3D* 'ActiveDocument)))
Although LISP is good and still working, the COM interfaces used accessible from LISP to customize Civil 3D are not evolving anymore, all new features and improvements are coming to .NET API (which we cannot access from LISP).
In general, consider LISP+COM a good way for small or prototype applications, and .NET for bigger and more complex. Also C++ can access both COM and .NET, but it's a more complicated language for beginners.
To access Civil 3D APIs from stand alone application you need COM. You can either use native built-in COM APIs inside Civil 3D or expose .NET features through COM interfaces, see more at http://through-the-interface.typepad.com/through_t
Access from outside have advantages, but in general the COM interface add complexity and, therefore, speed/performance cost. Not much, but should be considered if you application does lots of data interchange with Civil 3D.
Yes, it's consistent between 2012 and 2013, but note that binary incompatibility between those two version will force applications that run inside Civil 3D to be rebuild, nothing complicated though, see at http://adndevblog.typepad.com/autocad/2012/04/migr
Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register
Start with some of our most frequented solutions to get help installing your software.