Get all entities for a layer #497
Replies: 1 comment
-
Hi @JorenPelfrene, Recently there has been issues with the package versioning, make sure that you have the latest version. If About the name of blocks, all records are case insensitive, so all the entities in the model should be in the block *Model_Space regarding the caps. I'll add a feature PR to add some utility methods like getting the entities from a layer. |
Beta Was this translation helpful? Give feedback.
-
Is there a way to get all entities connected to a specific layer in the document?
I have some peculiar files where I can view the drawing with DWG TrueView. A few polylines are visible in a certain layer from the model space. But when reading in this document with ACadSharp, it shows no entities in CadDocument.Entities or CadDocument.ModelSpace.Entities. No other block records than the default model space and paper space are present. I can only retrieve some information on this one layer (other than '0'), but no option to find back the entities connected to it.
Thanks!
Edit:
I have a suspicion why I can't seem to identify these entities in the file with ACadSharp. But I could be wrong...
In all the files where CadDocument.Entities shows up empty, the model space name is "*MODEL_SPACE" (all caps), while BlockRecord.ModelSpaceName is strictly "*Model_Space" in ACadSharp. Could that be a cause for ACadSharp missing the entities here?
Regardless, it would be a useful feature to also be able to retrieve entities from the layer.
Beta Was this translation helpful? Give feedback.
All reactions