[V8i VBA] ICustomHook_PreDeleteHook broke feature connectivity

Hello all,

simply i try to add delete restrictions for specific features  this is my code:

Public Function ICustomHook_PreDeleteHook(ByVal Context As String, _
oFeature As xft.IFeature, _
bCancel As Boolean, _
Message As String) As Long

Debug.Print "xfmStdElecLib>XFMStdPlacementHooks.ICustomHook_PreDeleteHook"
' Set bCancel to true will stop feature action from happening
' if bCancel is true message will be displayed in the message center
If oFeature.name = "BUDELEC_E_STREETLIGHTBANK" Or oFeature.name = "BUDELEC_E_STREETLIGHTUNIT" Then
bCancel = True
Message = "Unable to delete"
End If

End Function

every thing is fine but after i try to edit this feature BEConnectivity throw this exertions:

Also feature can't move.

Thanks.

Parents Reply Children
No Data