.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

[.NET] Delete duplicates (Overkill not working in this case)

5 REPLIES 5
Reply
Message 1 of 6
AdriDicri
2229 Views, 5 Replies

[.NET] Delete duplicates (Overkill not working in this case)

Hello everyone !

I'm working with autocad 2013, and i have to delete all duplicates entities.

I know there is the OVERKILL command but it's not working as I need. I need to delete all the duplicates.

Ex : In a drawing, 2 lines are exactly the same, and 1 is different. I need a function that erase the 2 first because they're duplicates and leave the last one on the drawing.

I can do it with a simple algorithm that compare every line with every other line, but it takes a very long time if there's too much line on the drawing.

Is there an other function to do this?

Thanks for replies.

Adri DiCri

P.S : Sorry for my english, not my mother tongue !

 

 

 

5 REPLIES 5
Message 2 of 6
fenton.webb
in reply to: AdriDicri

Please give more detail as to why OVERKILL isn't working for you...




Fenton Webb
AutoCAD Engineering
Autodesk

Message 3 of 6
AdriDicri
in reply to: fenton.webb

Hello fenton.webb

 

As i said, OVERKILL deletes just 1 of 2 duplicates entities, but i need that both entities to be deleted of the drawing, and single entities stays on the drawing.

Imagine a square composed by 2 triangles. I need to erase the duplicated diagonales and keep only the contour.

 

Or did I miss something with the OVERKILL function???

 

I hope it's clear enought 🙂

 

If not, i will try to post a DWG file to explain better 😉

 

Thanks for your reply !

 

Adri DiCri

Message 4 of 6
fenton.webb
in reply to: AdriDicri

Can't you just re-run the OVERKILL command until all have been removed?




Fenton Webb
AutoCAD Engineering
Autodesk

Message 5 of 6
arcticad
in reply to: fenton.webb

By your own explanation if you have two lines and you delete the one duplicate then the other line is no longer a duplicate and won't be erased.

 

If you wanted to limit checking every single object in the drawing against a single object. You could get the bounding box of the object and see if any object intersect or are contained within your area and then compare the objects agains that list, instead of the entire drawing.

 

 

 

---------------------------



(defun botsbuildbots() (botsbuildbots))
Message 6 of 6
AdriDicri
in reply to: AdriDicri

Ok, i will try this tomorrow at work 😉

 

Thanks.

 

Adri DiCri

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

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost