ArcGIS Pro 3.7 API Reference Guide
ArcGIS.Core.Data.Realtime Namespace / RealtimeFeatureClass Class / Truncate Method
Example

In This Topic
    Truncate Method (RealtimeFeatureClass)
    In This Topic
    Removes all features. This method must be called on the MCT. Use QueuedTask.Run.
    Syntax
    Public Shadows Sub Truncate() 
    public new void Truncate()
    Exceptions
    ExceptionDescription
    This method or property must be called within the lambda passed to QueuedTask.Run.
    Example
    Delete all current and previous observations
    {
      // Note: call within QueuedTask.Run()
      {
        //Must be called on the feature class
        using var rfc = streamLayer.GetFeatureClass();
        rfc.Truncate();
      }
    }
    Requirements

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

    ArcGIS Pro version: 3.0 or higher.
    See Also