ArcGIS Pro 3.7 API Reference Guide
ArcGIS.Desktop.Mapping Namespace / LasPointDisplayFilter Class / WithheldPoints Property
Example

In This Topic
    WithheldPoints Property (LasPointDisplayFilter)
    In This Topic
    Gets and sets the withheld points flag. Default value is false.
    Syntax
    Public Property WithheldPoints As Boolean
    public bool WithheldPoints {get; set;}
    Remarks
    If a point is marked as withheld, then it will not be included in any processing.
    Example
    Get and Set Display Filter
    {
      // Note: Needs QueuedTask to run
      {
        // get the current display filter
        LasPointDisplayFilter ptFilter = lasDatasetLayer.GetDisplayFilter();
        // display only ground points
        lasDatasetLayer.SetDisplayFilter(LasPointDisplayFilterType.Ground);
    
        // display first return points
        lasDatasetLayer.SetDisplayFilter(LasPointDisplayFilterType.FirstReturnPoints);
    
        // set display filter to a set of classification codes
        List<int> classifications = new List<int>() { 4, 5, 7, 10 };
        lasDatasetLayer.SetDisplayFilter(classifications);
    
        // set display filter to a set of returns
        List<ArcGIS.Core.Data.Analyst3D.LasReturnType> returns = new List<ArcGIS.Core.Data.Analyst3D.LasReturnType>()
            { ArcGIS.Core.Data.Analyst3D.LasReturnType.ReturnFirstOfMany};
        lasDatasetLayer.SetDisplayFilter(returns);
    
        // set up a display filter
        var newDisplayFilter = new LasPointDisplayFilter();
        newDisplayFilter.Returns = new List<ArcGIS.Core.Data.Analyst3D.LasReturnType>()
            { ArcGIS.Core.Data.Analyst3D.LasReturnType.ReturnFirstOfMany, ArcGIS.Core.Data.Analyst3D.LasReturnType.ReturnLastOfMany};
        newDisplayFilter.ClassCodes = new List<int>() { 2, 4 };
        newDisplayFilter.KeyPoints = true;
        newDisplayFilter.WithheldPoints = false;
        newDisplayFilter.SyntheticPoints = false;
        newDisplayFilter.NotFlagged = false;
        lasDatasetLayer.SetDisplayFilter(returns);
      }
    }
    Requirements

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

    ArcGIS Pro version: 3.2 or higher.
    See Also