Export (0) Print
Expand All

Size3D.IsEmpty Property

Gets a value that indicates whether this Size3D structure is empty.

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

public bool IsEmpty { get; }

Property Value

Type: System.Boolean
true if the Size3D structure is empty; otherwise, false. The default is false.

A Size3D structure with X, Y, and Z values set to 0 is not empty. An empty Size3D structure has X, Y, and Z values set to negative infinity. This is the only time a Size3D structure can have negative values.

The following example shows how to check if a Size3D structure is empty.

                        // Checks if a Size3D structure is empty 
                        // Returns Boolean

                        Size3D size1 = new Size3D(0, 0, 0);
                        Boolean isEmpty;

                        isEmpty = size1.IsEmpty;
                        // isEmpty is False  

                        // Displaying Results
                        syntaxString = "isEmpty = size1.IsEmpty;";
                        resultType = "Boolean";
						operationString = "Checking if a Size3D structure is empty";
                        ShowResults(isEmpty.ToString(), syntaxString, resultType, operationString);

.NET Framework

Supported in: 4.5.2, 4.5.1, 4.5, 4, 3.5, 3.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

© 2014 Microsoft