Draw order

  • Here's a question I received recently from Dustin Vest, who works as a PDMS administrator at Fluor: I am having a problem with Intergraph's SmartSketch dwg files it exports... I found some code on your site that got me into the blocks, but I can't seem to change the draworder of entities within the block. SmartPlant 3D exports all the symbols as blocks but with wipeouts on top of the rest of the block. Dustin provided some code that was very nearly working – it really didn't need much work to get it in shape – and has kindly allowed…

  • As Scott has announced over on his blog, January's Plugin of the Month, DrawOrder By Layer, is now available on Autodesk Labs. I first posted the code for this very useful plugin back in October, and this version includes only a very minor change from that one (for performance reasons it now only works with modelspace layers). A huge thanks to Terry Dotson from DotSoft for generously donating this plugin. After the original post, a few people provided feedback on user interface enhancements they'd like to see in the tool – thanks for taking the time to do so, those…

  • Terry Dotson has – once again – generously offered an application to be an ADN Plugin of the Month. This little tool, called DrawOrderByLayer, allows you to modify the draw-order of objects in an AutoCAD drawing according to the layer they're on. I don't expect this to go live for another month or so (I still have plans for November's plugin), but I did want to post it in order to give people the chance to provide feedback. Here's basically how it works… You have layers containing geometry – in this case I've created circular solid hatches on layers named…

  • This question came in from Limin as a comment in this previous post: Is there .Net interface for autocad command "DrawOrder"? For example: after solid-hatch a polyline, need to reorder polyline and hatch, how to make it happen using .NET? I've put together some C# code to demonstrate how to do this: using Autodesk.AutoCAD.ApplicationServices; using Autodesk.AutoCAD.DatabaseServices; using Autodesk.AutoCAD.EditorInput; using Autodesk.AutoCAD.Runtime; namespace HatchDrawOrder {   public class Commands   {     [CommandMethod("HDO")]     static public void HatchDrawOrder()     {       Document doc =         Application.DocumentManager.MdiActiveDocument;       Editor ed = doc.Editor;       // Ask…