CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor and other Autodesk products []
Cesky English Deutsch
 Visitors: 2841 
Plex.Earth connects AutoCAD and Google Earth

CAD tip CAD tip # 6601:

Question CAD 
 %  platform  category 
Q - question

How to get World coordinates from the ID command?

A - answer The ID command returns coordinates in the current UCS. If you want to get XYZ coordinates of the picked point always in the global, world UCS (WCS) - regardles of the active user coordinate system - you can use the following simple LISP macro.

Just save it to WID.LSP, load it with Appload and start the WID command (similar to ID):

;World ID
;3/2009 -
(defun C:WID ( / pt) 
(setq pt (getpoint "\nPick a point to ID in World UCS: ")) 
(if pt
 (prompt (strcat "\nWorld  X = " (rtos (car (trans pt 1 0)) 2)
                      "    Y = " (rtos (cadr (trans pt 1 0)) 2)
                      "    Z = " (rtos (caddr (trans pt 1 0)) 2)))
100% *  CAD 
27.3.2009    7686x  
Comments   Tell a friend
applies to: AutoCAD ·

See also:
Tip 10222:How to add keyboard pan (shift view) to AutoCAD?
Tip 7258:Export of point- and curve coordinates to Excel.
Tip 6977:How to scale all texts in a drawing while keeping their position?
Tip 6860:The many shapes of AutoCAD UCS icons.
Tip 6572:My cursor crosshair displays rotated. Why?

Back   All CAD Tips All CAD tips&tricks

How to create AutoCAD geometry from Excel? « | » How to detect all DWG files containing Xrefs?

Have we helped you? If you want to support the CAD Forum web service, consider buying one of our CAD applications, or our custom software development offerings, or donating via PayPal (see above). You may also add a link to your web - like this "fan" link: CAD Forum - tips, utilities, blocks for Autodesk products
CAD:    OS:    Categ: 
Text:  FAQ glossary   

Increase your productivity with our set of BIM add-on functions for Autodesk Revit
CADstudio Revit Tools More info

Please use these tips at your own risk.
CAD Studio (Xanadu) is not responsible for possible problems that may occur as a result of using any of these tips.