ssm-jt Posted March 2, 2012 Posted March 2, 2012 is there a way to extract C3D object data using lisp? Quote
Tharwat Posted March 2, 2012 Posted March 2, 2012 Welcome to forum , what kind of 3d objects and what data you looking for ? Quote
Lee Mac Posted March 2, 2012 Posted March 2, 2012 I don't use C3D, but from other examples, I think you need to use an instance of the AeccXUiLand.AeccApplication object. Quote
ssm-jt Posted March 2, 2012 Author Posted March 2, 2012 comapny has recently switch to C3D, i have written many lisp routines that work with our old road design software that no longer work for various reasons. That being said, an example would be, i want to be able to select a profile object and switch the current UCS to match the profile elevation and stations. Quote
rickh Posted March 2, 2012 Posted March 2, 2012 From everything I've found (limited as it may be), I am always pointed towards .net to access all the civil3d features. Quote
bcinnv Posted March 5, 2012 Posted March 5, 2012 SSM-JT... I am struggling to understand what you're trying to do, or what you're trying to get. I'm hope you're not being cryptic due to proprietary reasons. It's not a good way to get assistance through a public forum. If you need assistance privately please message me. That said: if you want to extract information from the profile I've done it by using data attached to the profile view... slightly inconvenient, but I was able to use visual lisp, which I was already familiar with. It would be best to learn .NET if you plan to continue customization throughout your career. I don't. Good luck! Quote
BIGAL Posted March 6, 2012 Posted March 6, 2012 Some example of contour info, alignments should be similar like above if serious use .net (defun ah:vercheck () (vl-load-com) (if ((lambda (vrsn) (cond ((vl-string-search "R17.2" vrsn) (setq appstr "6.0")) ;09 ((vl-string-search "R18.0" vrsn) (setq appstr "7.0")) ;10 ((vl-string-search "R18.1" vrsn) (setq appstr "8.0")) ;11 ((vl-string-search "R18.2" vrsn) (setq appstr "9.0")) ;12 ((alert "This version of C3D not supported!")) ) ) (vlax-product-key) ) ; end if condition progn is true (progn (cond (*AeccDoc*) ((setq *AeccDoc* (vlax-get (cond (*AeccApp*) ((setq *AeccApp* (vla-getinterfaceobject (cond (*Acad*) ((setq *Acad* (vlax-get-acad-object))) ) (strcat "AeccXUiLand.AeccApplication." appstr) ) ) ) ) 'ActiveDocument ) ) ) ) ; end main cond ) ; end progn ) ; end if vsrn ) (vlax-for j (vlax-get *AeccDoc* 'SurfaceS) (setq lst (cons (cons (vla-get-name j) j) lst)) (vlax-for k (vlax-get *AeccDoc* 'SurfaceS) (if (= Surfacepick (vla-get-name k)) ;match surface (vlax-put k 'Style (cdr (assoc surface lst))) ) ; end if ) ; end vlax-for ) Quote
ssm-jt Posted March 6, 2012 Author Posted March 6, 2012 i dont mean to be "criptic", no hidden agenda, and everything i have found, also directs me to .net. Took me long enough to learn lisp, and its just a shame that alot of lisp routines that i wrote to help me along with "my" road design process are now useless because i cant access most of an objects properties for what ever autodesks reasons are. i have a hate on for Autodesk and C3D right now. Quote
SLW210 Posted March 6, 2012 Posted March 6, 2012 Civil 3D still has vanilla AutoCAD availble, doesn't it? Quote
BIGAL Posted March 7, 2012 Posted March 7, 2012 I posted lisp code for getting surface info I also do the same for points did you read it ? It is a case of finding out the Autocad alignment naming to get at there properties it can be done! Have a look at the sample files under Civil 3d API etc VBA on the older versions there was good code examples. Quote
rickh Posted March 7, 2012 Posted March 7, 2012 comapny has recently switch to C3D Our company also switched only 2 yrs ago....coming from Microstation with a lot of custom macros and other stuff to make profiles and cut sheets etc. (needless to say the robotic workers were very disappointed). I must say that once we started actually learning the best methods to use Civil 3D it really is a lot faster to get production drawings out, and more accurate for revisions. Another benefit is that we don't have to have a massive amount of customization to keep track of when the base software is updated. We rely more now on the product we paid for than on the time we spend customizing it. I'm not saying you can't hate Autodesk....just throwing in my two cents to support the software. And really, it's like SLW210 was getting at - you can still do all the autocad stuff within C3D if you think it is a better route. Quote
bcinnv Posted March 9, 2012 Posted March 9, 2012 We can help you better if you tell us exactly what you're trying to do. A blanket "can we access Civil 3d objects" is a broad statement. I'm guessing you deleted my previous reply, but I am/was just trying to help. Please state exactly what you want to do, and we can direct a better answer. In short... the answer is, some objects can be accessed. Some manipulated through built in c3d commands. Some using vl-load-com. If you tell us the routines you are trying to write, we can help better. Anyway... that's all I was trying to say. Quote
BIGAL Posted March 27, 2012 Posted March 27, 2012 google civil3ddevelopersguide.pdf I have a copy it has all sorts of stuff in it like 15 pages of coding for alignments. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.