ArcGIS Pro 3.5 API Reference Guide
ArcGIS.Desktop.Core Namespace / ExploratoryAnalysisOptions Class / SetElevationProfileOptionsAsync Method
The new elevation profile options
Example

In This Topic
    SetElevationProfileOptionsAsync Method
    In This Topic
    Sets the elevation profile options.
    Syntax
    public Task SetElevationProfileOptionsAsync( 
       ElevationProfileOptions elevationProfileOptions
    )
    Public Function SetElevationProfileOptionsAsync( _
       ByVal elevationProfileOptions As ElevationProfileOptions _
    ) As Task

    Parameters

    elevationProfileOptions
    The new elevation profile options
    Exceptions
    ExceptionDescription
    elevationProfileOptions is null.
    Elevation profile options are not valid. See CanSetElevationProfileOptions for details on option settings.
    Remarks
    This method calls the CanSetElevationProfileOptions function prior to setting the option values. If the options are invalid, no updates are made.
    Example
    Customize Elevation Profile Graph Display
    // customize the elevation profile graph options
    var options = new ElevationProfileOptions()
    {
      LineColor = ColorFactory.Instance.CreateRGBColor(0, 0, 100),
      ShowAverageSlope = false, 
      ShowMaximumSlope = false
    };
    
    var eaOptions = ApplicationOptions.ExploratoryAnalysisOptions;
    if (eaOptions.CanSetElevationProfileOptions(options))
      await eaOptions.SetElevationProfileOptionsAsync(options);
    
    
    // or reset to default options
    var defaultOptions = eaOptions.GetDefaultElevationProfileOptions();
    if (eaOptions.CanSetElevationProfileOptions(defaultOptions))
      await eaOptions.SetElevationProfileOptionsAsync(defaultOptions);
    
    Requirements

    Target Platforms: Windows 11, Windows 10

    ArcGIS Pro version: 3.4 or higher.
    See Also