ArcGIS Pro 3.7 API Reference Guide
ArcGIS.Desktop.Mapping Namespace / VoxelLayer Class / UpdateSection Method
The definition of the locked section to update
Example

In This Topic
    UpdateSection Method (VoxelLayer)
    In This Topic
    Update the specified locked section. This method must be called on the MCT. Use QueuedTask.Run.
    Syntax
    Public Sub UpdateSection( _
       ByVal lockedSectionDef As LockedSectionDefinition _
    ) 
    public void UpdateSection( 
       LockedSectionDefinition lockedSectionDef
    )

    Parameters

    lockedSectionDef
    The definition of the locked section to update
    Exceptions
    ExceptionDescription
    This method or property must be called within the lambda passed to QueuedTask.Run
    Locked section not found in the collection of sections
    Locked section is null
    Example
    Update Locked Section Visibility
    {
      // Note: call within QueuedTask.Run()
      {
        if (voxelLayer.Visualization != VoxelVisualization.Surface)
          voxelLayer.SetVisualization(VoxelVisualization.Surface);
        voxelLayer.SetLockedSectionContainerExpanded(true);
        voxelLayer.SetLockedSectionContainerVisibility(true);
    
        var locked_sections = voxelLayer.GetLockedSections().Where(ls => !ls.IsVisible);
    
        //Make them visible
        foreach (var locked_section in locked_sections)
        {
          locked_section.IsVisible = true;
          //apply change
          voxelLayer.UpdateSection(locked_section);
        }
      }
    }
    Requirements

    Target Platforms: Windows 11 Home, Pro, Enterprise (64 bit)

    ArcGIS Pro version: 3.0 or higher.
    See Also