VisualChildrenCount Property

Visual::VisualChildrenCount Property

 

Gets the number of child elements for the Visual.

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

protected:
property int VisualChildrenCount {
	virtual int get();
}

Property Value

Type: System::Int32

The number of child elements.

By default, a Visual has no children. Therefore, the default implementation always returns 0.

Notes to Inheritors:

A class that derives from Visual must override this property, and also the GetVisualChild method, for the visual tree to be enumerated correctly.

The following example defines an overridden implementation of VisualChildrenCount.

No code example is currently available or this language may not be supported.

.NET Framework
Available since 3.0
Return to top
Show:
© 2016 Microsoft