Share via


ExtendedProperties.Remove Method

ExtendedProperties.Remove Method

Removes an ExtendedProperty object from the ExtendedProperties collection.

Definition

Visual Basic .NET Public Sub Remove( _
ByVal id As Guid _
)
C# public void Remove(
Guid id
);
Managed C++ public: void Remove(
Guid *id
);

Parameters

id System.Guid. The globally unique identifier (GUID) of the ExtendedProperty object to remove from the ExtendedProperties collection.

Remarks

This method removes the ExtendedProperty object only from a snapshot of, or reference to, the ink data and does not remove the ExtendedProperty object from the actual ink data.

Examples

[C#]

This C# example removes a timestamp, which is stored as an ExtendedProperty object, from a Strokes collection, theStrokes.

//...
    theTimeGuid = new Guid( ... );
//...
    // Strip the timestamp property from theStrokes.
    Strokes theStrokes = theInkCollector.Ink.Strokes;
    foreach (Stroke theStroke in theStrokes)
    {
        // Test for the timestamp property on this stroke.
        if (theStroke.ExtendedProperties.DoesPropertyExist(theTimeGuid))
        {
            // Strip the data out of this stroke's extended
            // properties list.
            theStroke.ExtendedProperties.Remove(theTimeGuid);
        }
    }
//...
                

[VB.NET]

This Microsoft® Visual Basic® .NET example removes a timestamp, which is stored as an ExtendedProperty object, from a Strokes collection, theStrokes.

'...
    Dim theTimeGuid As New Guid( ... )
'...
    'Strip the timestamp property from theStrokes.
    Dim theStrokes As Strokes = theInkCollector.Ink.Strokes
    Dim theStroke As Stroke
    For Each theStroke In theStrokes
        'Test for the timestamp property on this stroke.
        If theStroke.ExtendedProperties.DoesPropertyExist(theTimeGuid)_
        Then
            'Strip the data out of this stroke's extended
            'properties list.
            theStroke.ExtendedProperties.Remove(theTimeGuid)
        End If
    Next
'...
                

See Also