Matrix.Parse Method (String)

 

Converts a String representation of a matrix into the equivalent Matrix structure.

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

public static Matrix Parse(
	string source
)

Parameters

source
Type: System.String

The String representation of the matrix.

Return Value

Type: System.Windows.Media.Matrix

The equivalent Matrix structure.

The following example shows how to convert a string representation of a matrix into a Matrix structure.

private Matrix parseExample()
{

    Matrix result = Matrix.Parse("1, 2, 3, 4, 5, 6");

    // result is equal to (1,2,3,4,5,6).
    return result;

}

.NET Framework
Available since 3.0
Return to top
Show: