Hi All,
Just wondering if anybody has a solution to my problem. I am working on drawings where we create dtm's from surfaces, use the dtm for layout, shoot the asbuilt of the final surface, and then compare hundreds of shots to the surface to develop an as-build report.
I want to be able to select a mass of points, compare the perpindicular difference in elevation to the surface, and have an excel spread sheet generated from the results.
My coworkers are able to do this in Terramodel but I am on a mission to eliminate Terramodel from my day to day work.
Just hoping somebody may have come across this before and can shed some light as to what commands or add-ons are availbable. I've never worked with a LISP but i am certainly open to suggestions at this point.
Solved! Go to Solution.
Solved by tcorey. Go to Solution.
Use APPLOAD command to load it, then type go at the command prompt to make it run.
SIR I TRY YOUR LISP BUT NOT GIVE ANSWER IN EXCEL.YOU CAN SEND ME SOME SCREEN SHOTS.OR LISP AGAIN MY MAIL
The LISP writes a file called c:\PointDepth.txt, which can be opened with Excel.
Dear sir,
i attached my points and lisp file please check and send me corrected lisp.i cant get value.
That was meant to report on COGO Points. You have AutoCAD Points.
I revised the lisp so that it reports on AutoCAD Points. It will also now write the report file into the same folder as the drawing. The report will be named the same as the drawing name, plus _PointDepth.txt. For example: ELEV. DEFFERENCE STUDY_PointDepth.txt
(defun c:go ( / srf vsrf fl pts len ctr p vp pno x y elv srfz depth elvx srfzx output) (setq srf (vlax-ename->vla-object (car (entsel "\nSelect reference surface: ")))) (setq fl (open (strcat (filenamegetter) "_PointDepth.txt") "w" ) ) (write-line "PointElevation, SurfaceElevation, DistanceToSurface" fl) (prompt "\nSelect points to report: ") (setq pts (ssget)) (setq len (sslength pts) ctr 0) (while (< ctr len) (setq p (ssname pts ctr)) (if (= (cdr (assoc 0 (entget p))) "POINT") (progn (setq vp (vlax-ename->vla-object p) x (car (vlax-get vp 'Coordinates)) y (cadr (vlax-get vp 'Coordinates)) elv (caddr (vlax-get vp 'Coordinates)) ) (setq srfz (vlax-invoke-method srf 'FindElevationAtXY x y)) (setq depth (rtos (- srfz elv) 2 3)) (setq elvx (rtos elv 2 3) srfzx (rtos srfz 2 3) ) (setq output (strcat elvx "," srfzx "," depth)) (write-line output fl) ) ) (setq ctr (1+ ctr)) ) (close fl) (princ) ) (defun filenamegetter ( / ) (setq pref (getvar "DWGPREFIX") dwgnm (substr (getvar "dwgname") 1 (- (strlen (getvar "dwgname")) 4)) ) (setq dwgnm (strcat pref dwgnm)) )
Dear Timoty,
I've stumbled upon this thread and hoping to try this lisp out but I'm getting this error message.
Any chance why this is happening. Civil 3D 2019 64bit.
"Select objects: 1 found
Select objects:
20481,78.04,361.31,283.27
; error: bad argument type: streamp nil"
Are you selecting AutoCAD points or Civil 3D COGO Points? It makes a difference.
Tim
Hi,
I'm using cogopoints. Is't possible to get a column for the surface height of that particular point (for validatio purposes) and a column for description?
Kind Regards
Fadi
Hi
The report is not perpendicular instead its vertical. It wont work in Batter or surface with slope.
Is there anyone that solves this issue?
Hello,
The lisp is reporting the vertical distance from a surface to a point and not a 3d distance perpendicular to a surface. This will not work in surface like batter and with slope. Please is there anyone who can solve the issue.
Thanks.
Please is there anyone who can solve the issue.
Seems to me there are three possible solutions. The first instance of this distance between problem has been addressed.
Detailed reporting would require each vectors azimuth and vertical angle along with the slope distance.
I'm getting the same error and I am using COGO points for the first lisp and AutoCad points for the second. Any help would be appreciated.