Community
AutoCAD Forum
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Any ability to display the z value of a point in AutoCAD 2007?

5 REPLIES 5
Reply
Message 1 of 6
jeshuare
2573 Views, 5 Replies

Any ability to display the z value of a point in AutoCAD 2007?

Hi all. My employer enforces CivilCAD 5.72 use (I'm used to C3D, but hey, a job is a job), and we export from that to a DWG for our client. Now, whilst the text fo the z value does appear, CivilCAD's export process throws it all into the one layer. As such, there is no easy way to quickly determine what height the walls are for instance, by just turning the wall layer on. 

 

Now, I've seen people suggest creating a block with fields and attributes, but given that some of our level and feature surveys run into the thousands of points, I'd rather not have to sit there clicking each point individually inserting a block if I can avoid it. 

 

Is there any possible way to either:

 

A) Simply display the z value next to each point, just like CivilCAD, GeoCivil or C3D can?

 

B) If I have to go down the block and field path, is there anyway to insert a block to every point in the drawing at once?

 

Thanks

5 REPLIES 5
Message 2 of 6
3wood
in reply to: jeshuare

There are a lot of routines available to insert a block at multiple selected points.

Message 3 of 6
jeshuare
in reply to: 3wood

Thanks for the kind of reply. I take it to infer then that option a) doesn't exist in AutoCAD 2007?

Message 4 of 6
braudpat
in reply to: jeshuare

 

Hello

 

Welcome to the Autodesk/AutoCAD Forums !

 

Which kind of routine do you need exactly ?

 

- Insert a Block where is a XYZ Point

- Insert a Block with ONE attribute (which is the Altitude) where is a XYZ Point

- Insert a XYZ Point where is a Text (which is in fact the Altitude)

- other ?

 

 

Patrice ( Supporting Troops ) - Autodesk Expert Elite
If you are happy with my answer please mark "Accept as Solution" and if very happy please give me a Kudos (Felicitations) - Thanks

Patrice BRAUD

EESignature


Message 5 of 6
jeshuare
in reply to: braudpat

Thanks for the reply Pat. In answer to your question, it would be the second one. The points exist, with XYZ, but they have no associated text. And whilst the RL is displayed as text, it's in it's own layer. Is there a way to get the blocks to come in as the same layer as the individual points that they are snapping to?

Message 6 of 6
braudpat
in reply to: jeshuare

 

Hello from France

 

Sorry for the delay, I was in holidays

 

So I think that this routine "P2B1" will solve your problem !?

 

I have slighly modified an existing routine (Sorry I don't know the Author) ...

And please remind that I am not a programmer !

 

 

 
;;; 
;;; Routine pour dessiner un Bloc (avec UN attribut) sur des points graphiques
;;; Version 2.1 corrigee pour ne traiter que des Points et remplir UN attribut 
;;; - RTOS qui permet de transformer un réel en chaine à l'arrondissant 
;;; - ATOF qui permet de transformer une chaine en réel 
;;;
;;; 
;;; Commande:  P2B1
;;;
;;;--------------------------------------------------------------------;
;;; PNT2BLK.LSP (--> P2B1)  -  July 2001 - Original Routine 
;;; Place a block object in the location of selected point objects.
;;;--------------------------------------------------------------------;
;;; 
;;; Function: PNT2BLK --> P2B1   - Function to convert point objects to blocks
;;; Block must be already defined (or inserted) in the current drawing
;;; Block must have ONE attribute which will be populated with Z (Altitude) 
;;; 


(defun c:P2B1 ( / ss ct len e eb bname pt attdiahold echohold ALTZ NB_ARR )

;;; get command echo setting and store it
(setq echohold (getvar "CMDECHO"))

;;; set command echo off
(setvar "CMDECHO" 0)

;;; get attribute request setting and store it
(setq attdiahold (getvar "ATTDIA"))
(setvar "ATTDIA" 0)

;;; set attribute request ON
(setvar "ATTREQ" 1)

;;; get name of block to insert
(setq bname (getstring "\nBlock name: "))

;;; check that the block is defined in the current drawing
(if (tblsearch "block" bname)
(progn

;;; prompt for point selection
(princ "\nSelect point objects:")

;;; --- if point were selected ---

(if (setq ss (ssget '((0 . "POINT"))))

(progn

;;; walk through point objects
(setq len (sslength ss))
(setq ct 0)
(while (< ct len)

;;; for each point
(setq e (ssname ss ct))
(setq ct (+ ct 1))
(setq eb (entget e))

;;; get insert point
(setq pt (cdr (assoc 10 eb)))

;;; get attribute value : Z --> ALTZ 

;;; more than 10 decimals
; (setq ALTZ (caddr pt) ) 

;;; NB_ARR = number of decimals = 2 (default)
(setq NB_ARR 2) 
(setq ALTZ        (rtos (caddr pt) 2 NB_ARR ) ) 

;;; insert the block
(command "_insert" bname pt "" "" "" ALTZ)

)
)
(princ "\nNo point  objects selected.")
)
)
(princ "\nInvalid, block not defined in drawing.")
)

;;; restore command echo setting to stored value
(setvar "CMDECHO" echohold)

;;; restore attribute request setting to stored value
(setvar "ATTDIA" attdiahold)

(princ)
) 

 

 

Patrice ( Supporting Troops ) - Autodesk Expert Elite
If you are happy with my answer please mark "Accept as Solution" and if very happy please give me a Kudos (Felicitations) - Thanks

Patrice BRAUD

EESignature


Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost