ArcGIS Pro 3.2 API Reference Guide
ArcGIS.Desktop.Mapping.Voxel Namespace / VoxelVariableProfile Class / DeleteIsosurface Method
The definition of the isosurface to delete.
Example

In This Topic
    DeleteIsosurface Method
    In This Topic
    Delete the specified isosurface. This method must be called on the MCT. Use QueuedTask.Run.
    Syntax
    public void DeleteIsosurface( 
       IsosurfaceDefinition isosurfaceDef
    )
    Public Sub DeleteIsosurface( _
       ByVal isosurfaceDef As IsosurfaceDefinition _
    ) 

    Parameters

    isosurfaceDef
    The definition of the isosurface to delete.
    Exceptions
    ExceptionDescription
    This method or property must be called within the lambda passed to QueuedTask.Run.
    Isosurface not found in the collection of isosurfaces.
    Example
    Delete Isosurface- s
    //var voxelLayer = ... ;
    //Must be on the QueuedTask.Run()
    
    var variable = voxelLayer.SelectedVariableProfile;
    
    //delete the last surface
    var last_surface = variable.GetIsosurfaces().LastOrDefault();
    
    if (last_surface != null)
    {
        variable.DeleteIsosurface(last_surface);
    }
    
    //delete all the surfaces
    foreach (var surface in variable.GetIsosurfaces())
        variable.DeleteIsosurface(surface);
    
    //Optional - set visualization back to Volume
    if (variable.GetIsosurfaces().Count() == 0)
    {
        voxelLayer.SetVisualization(VoxelVisualization.Volume);
    }
    
    Requirements

    Target Platforms: Windows 11, Windows 10

    ArcGIS Pro version: 3 or higher.
    See Also