<< Click to Display Table of Contents >> Navigation: How To > How to ask for confirmation before a deletion |
There are two ways of “confirming the deletion”:
1. Library will ask before deleting entities, handles of which are specified in the <CustomSelectMode> parameters:
<?xml version="1.0" encoding="utf-8"?> |
2. Event="OnConfirmEntitiesDeletion"
Event allows to control it from your application if you wish to delete an entity or not.
<?xml version="1.0" encoding="UTF-8"?> |
When the user wants to delete an entity, CADEditorX will not delete it, just the event will be called with the result like here:
<cadsofttools version="2.0"> |
In this event, our demo (not CADEditorX itself) shows message like this:
And after clicking “Yes” it runs xml to delete the selected entities:
<?xml version="1.0" encoding="UTF-8"?> |
So, you can activate such a dialog in your application and delete entities after pressing OK in your confirmation dialog.
Go to CADEditorX