Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

PathSegmentCollection.Add Method

Adds a PathSegment to the end of the collection.

Namespace:  System.Windows.Media
Assembly:  PresentationCore (in PresentationCore.dll)

public void Add(
	PathSegment value


Type: System.Windows.Media.PathSegment

The segment to add to the collection.




value is null.


The PathSegmentCollection is read-only.

- or -

The PathSegmentCollection has a fixed size.

Because PathSegment objects derive from Freezable, they are copied when they are used. Therefore, you might not be able to later retrieve or remove the PathSegment you added to the collection using the original PathSegment object; the PathSegment in the collection is a copy of the original PathSegment and is considered a different PathSegment than the one you added.

Unlike typical implementations of ICollection<T>.Add, this implementation throws an ArgumentException if you attempt to add a null (Nothing) reference.

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5, 3.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1
© 2015 Microsoft