CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor, Revit and other Autodesk products [www.cadforum.cz] ARKANCE | CONTACT - CZ | SK | EN | DE

CAD tip CAD tip # 11179:

Question

CAD 
 %  platform  category 
A
Using the LISP filter "-4" you can easily select DWG objects, which have their definition/reference point above or below a given limit set on the individual X,Y,Z components of their coordinates. So you can select/filter objects with a reference point in a positive or negative Z-elevation, or in the positive XY half-space, or in the positive XYZ octant.

See examples of selecttion sets (can be input on the "Select objects:" prompt)

Negative Z-elevation:
(ssget "_X" '((-4 . "*,*,<")(10 0 0 0)))

Positive XY half-space, any Z:
(ssget "_X" '((-4 . ">=,>=,*")(10 0 0 0)))

Positive XY half-space, only "zero" Z (flat):
(ssget "_X" '((-4 . ">=,>=,=")(10 0 0 0)))

Positive octant XYZ:
(ssget "_X" '((-4 . ">=,>=,>=")(10 0 0 0)))

You can also combine the filters through AND, OR, NOT. Please note that only the reference point is checked (e.g. a circle center, polyline starting point), not the whole bounding box of a drawing entity.

ACAD
100% *CAD
22.11.2016    7218×  
applies to: AutoCAD ·

See also:
Tip 14620:Converting object data (OD) to XData (XD) in AutoCAD Map 3D.
Tip 13737:Formatting leading zeros in AutoCAD fields (and automatic field update).
Tip 13716:HYPERLIST - list of all used URLs.
Tip 13688:How to select all DWG objects of a certain type in AutoCAD LT? (texts, circles...)
Tip 13049:Bulk 3D rotation of selected objects around individual axes.


Back    All CAD Tips



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
  



Featuring:
Increase your productivity with our set of BIM add-on functions for Autodesk Revit
Be.Smart T4R More info


Please use these tips at your own risk.
ARKANCE is not responsible for possible problems that may occur as a result of using any of these tips.
TOPlist