Select to view content in your preferred language

OnFeatureDeleted

826
2
Jump to solution
02-25-2013 03:45 AM
Dag_MartinRomslo
Emerging Contributor
Is there a way to get Field-data or geometry from a feature as it is being deleted? I need the ID of my deleted feature to use in further program logic, and it seems I can not get this in the layer's OnFeatureDeleted event...
Tags (3)
0 Kudos
1 Solution

Accepted Solutions
GarethWalters
Deactivated User
Hi Dag,

Before you delete the feature you must select it via script or UI. Therefore you have the Map.SelectionBookmark that you can find all of the details of the feature.

If you use the Map.OnSelectionChanged event you can discover the details of the bookmark and traverse to the details. Write all the details you need before you delete it.

Let me know how you go.

Cheers,

Gareth

View solution in original post

0 Kudos
2 Replies
GarethWalters
Deactivated User
Hi Dag,

Before you delete the feature you must select it via script or UI. Therefore you have the Map.SelectionBookmark that you can find all of the details of the feature.

If you use the Map.OnSelectionChanged event you can discover the details of the bookmark and traverse to the details. Write all the details you need before you delete it.

Let me know how you go.

Cheers,

Gareth
0 Kudos
Dag_MartinRomslo
Emerging Contributor
Thanks Gareth.

That's how I solved it, and it works fine.
0 Kudos