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

Integrate custom objects/entities with purge process?

5 REPLIES 5
SOLVED
Reply
Message 1 of 6
maisoui
570 Views, 5 Replies

Integrate custom objects/entities with purge process?

Hi,

 

I wonder if there is a way to say to the purge command that my custom objects/entities are "purgeable"? Maybe a method similar to audit exists? My goal is to obtain something like this :

 

purgedialog.png

 

User will be able to clean useless custom objects (acting like AcDbSymbolTableRecord) in dictionaries per example.

 

Regards,

--
Jonathan
5 REPLIES 5
Message 2 of 6
Balaji_Ram
in reply to: maisoui

Hi Jonathan,

 

I do not find any way to have the custom objects that are purgeable listed inside the purge dialog. AutoCAD collects the object Id of the entities/objects that it wants to test and uses the AcDbDatabase::purge to determine if they are really purgeable. The ObjectId of custom objects inside the Custom dictionaries are not included in this test and so do not get listed.

 

But your plugin can still use the AcDbDatabase::purge method to test if your custom objects are purgeable.

Simply gather the ObjectId of the custom objects that you would want to test and and AcDbDatabase::purge will tell you if they are purgeable. The custom dictionary is a soft owner for the custom objects and so custom objects are purgeable unless there is a hard reference to it from any other entity / object.

 

Regards,

Balaji

 



Balaji
Developer Technical Services
Autodesk Developer Network

Message 3 of 6
Balaji_Ram
in reply to: maisoui

Hi Jonathan,

 

I have contacted our engineering team on this topic to see if they have anything to add to this topic.

 

I will keep you updated.

 

Regards,

Balaji 

 



Balaji
Developer Technical Services
Autodesk Developer Network

Message 4 of 6
maisoui
in reply to: Balaji_Ram

Thank you very much.

Regards,

--
Jonathan
Message 5 of 6
Balaji_Ram
in reply to: maisoui

Hi Jonathan,

 

I have heard from our engineering team that this is not possible at present. 

 

This feature was not considered since it might be risky to have the custom entities and objects purged only because they do not have hard references. Such objects / entities may be required by custom applications and we do not want the user to inadvertently purge them.

 

You can create a custom purge command that can deal with your objects and entities using the AcDbDatabase::purge method.

 

Regards,

Balaji



Balaji
Developer Technical Services
Autodesk Developer Network

Message 6 of 6
maisoui
in reply to: Balaji_Ram

Ok. Thank you for the information.

Regards,

--
Jonathan

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

Post to forums  

Autodesk Design & Make Report

”Boost