ArcObjects Library Reference (Geometry)  

IGeometry4.Changed Property

Indicates if a geometry has been changed (edited, projected, etc).

[Visual Basic .NET]
Public Property Changed As Boolean
[C#]
public bool Changed {get; set;}
[C++]
HRESULT get_Changed(
  VARIANT_BOOL* isChanged
);
[C++]
HRESULT put_Changed(
  VARIANT_BOOL isChanged
);
[C++]

Parameters

isChanged [out, retval]   isChanged is a parameter of type VARIANT_BOOL isChanged   isChanged is a parameter of type VARIANT_BOOL

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Description

The Changed method returns whether or not the geometry has been modified. If the geometry always stays in memory that method only returns 'false' immediately after its creation. However if the shape came from disk the Changed method will return 'false' until de geometry is modified in memory.

[C#]

    //This example demonstrates how to use the Changed method
    private void Changed_Example()
    {
        IEnvelope envelope = new EnvelopeClass();
        envelope.PutCoords(0, 0, 20, 20);
        ISegmentCollection segmentCollection = new PolygonClass();
        segmentCollection.SetRectangle(envelope);
        IGeometry4 geometry = segmentCollection as IGeometry4;
        System.Windows.Forms.MessageBox.Show("Just after creation : " + geometry.Changed);
        segmentCollection.SetRectangle(envelope);
        System.Windows.Forms.MessageBox.Show("Just after modification : " + geometry.Changed);
    }

See Also

IGeometry4 Interface