ジオメトリのチェック

Public Sub CheckGeometryError()
    Dim pFeatureSimplify2 As IFeatureSimplify2
    Set pFeatureSimplify2 = pFeature
    
    Dim pGeometry As IGeometry
    Set pGeometry = pFeature.Shape
        
    Dim enumReason As esriNonSimpleReasonEnum
    
    If pFeatureSimplify2.IsSimpleGeometry(pGeometry, esriNonSimpleRingOrientation) Then
        Debug.Print "esriNonSimpleRingOrientation"
    End If
    
    If pFeatureSimplify2.IsSimpleGeometry(pGeometry, esriNonSimpleSegmentOrientation) Then
        Debug.Print "esriNonSimpleSegmentOrientation"
    End If
    
    If pFeatureSimplify2.IsSimpleGeometry(pGeometry, esriNonSimpleShortSegments) Then
        Debug.Print "esriNonSimpleShortSegments"
    End If
    
    If pFeatureSimplify2.IsSimpleGeometry(pGeometry, esriNonSimpleSelfIntersections) Then
        Debug.Print "esriNonSimpleSelfIntersections"
    End If
    
    If pFeatureSimplify2.IsSimpleGeometry(pGeometry, esriNonSimpleUnclosedRing) Then
        Debug.Print "esriNonSimpleUnclosedRing"
    End If
    
    If pFeatureSimplify2.IsSimpleGeometry(pGeometry, esriNonSimpleEmptyPart) Then
        Debug.Print "esriNonSimpleEmptyPart"
    End If
    
    If pFeatureSimplify2.IsSimpleGeometry(pGeometry, esriNonSimpleMismatchedAttributes) Then
        Debug.Print "esriNonSimpleMismatchedAttributes"
    End If
    
    If pFeatureSimplify2.IsSimpleGeometry(pGeometry, esriNonSimpleDiscontinuousParts) Then
        Debug.Print "esriNonSimpleDiscontinuousParts"
    End If
    
    If pFeatureSimplify2.IsSimpleGeometry(pGeometry, esriNonSimpleEmptyZValues) Then
        Debug.Print "esriNonSimpleEmptyZValues"
    End If
    
    If pFeatureSimplify2.IsSimpleGeometry(pGeometry, esriNonSimpleDuplicateVertex) Then
        Debug.Print "esriNonSimpleDuplicateVertex"
    End If

End Sub