ArcGIS Pro 3.1 API Reference Guide
ArcGIS.Desktop.Core Namespace / ArcGISPortal Class / EnsureValid Method

In This Topic
    EnsureValid Method
    In This Topic
    Ensure the portal is a valid.
    Syntax
    public void EnsureValid()
    Public Sub EnsureValid() 
    Exceptions
    ExceptionDescription
    Thrown when an invalid portal is provided as the active portal.
    Remarks
    The portal is checked against the list of portals managed by the ArcGISPortalManager. If the portal is not in the list of portals an exception is thrown
    Requirements

    Target Platforms: Windows 11, Windows 10

    ArcGIS Pro version: 3.0 or higher.
    See Also