Visual LISP, AutoLISP and General Customization
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Help with Xref draw order lisp

2 REPLIES 2
Reply
Message 1 of 3
owainmeyer
517 Views, 2 Replies

Help with Xref draw order lisp

Hi Cad guru's,

I've been tasked with finding a lisp that allows us to precisely control the draw order of xrefs.

All our xrefs need to be on a single xref layer, so i can't use LeeMac's method of controlling independent layers.

I've found an old lisp routine (attached) but it doesn't work, and i have no idea why. 

 

Absolute beginner here so please explain like i'm 5!

Thanks!

Tags (2)
2 REPLIES 2
Message 2 of 3
dlanorh
in reply to: owainmeyer

Your "Lisp" is not a lisp, from a cursory glance it's .NET source code

I am not one of the robots you're looking for

Message 3 of 3
marko_ribar
in reply to: owainmeyer

When you attach Xref to DWG, independently of Layer Xref reside, Xref brings its own Layers to DWG... Each one of them looks like "Xrefname|Layername"... So instead of draw order for Xref as entities, you should apply Lee's draw order for Layers that have this kind of specifications "Xref1|Layer1", "Xref1|Layer2", ... , "Xref1|Layern", "Xref2|Layer1", "Xref2|Layer2", ... "Xref2|Layerm", ... , "Xrefx|Layer1", "Xrefx|Layer2", ... , "Xrefx|Layery". But as far as I can recall - sorting entities to Sortents table can be applied to each entity separately no mater what layer entity belongs to... Have a look at Lee's Draw Order sub routines from his site... IMHO you should iterate through all entities in for you specific order and apply movetotop or movetobottom sub functions in that exact order, so that final look could be as desired... And as far as I know you should do iteration on nested levels - I don't believe you can simply bring up or down whole INSERT entity (Block or Xref) with all nesting entities at once... FYI you have brilliant command "CDORDER" - Color Draw Order which does sorting by colors on all entities no matter if they are nested or not - very useful if you plan to plot your DWG based on colors of entities... For me I do this once as final step before presenting DWG - all the time while working I don't pay attention to Draw Order just at the end when drawing work is finished...

Marko Ribar, d.i.a. (graduated engineer of architecture)

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

Post to forums  

Autodesk Design & Make Report

”Boost