This documentation is archived and is not being maintained.

Matrix.M12 Property

Gets or sets the value of the first row and second column of this Matrix structure.

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

public double M12 { get; set; }
/** @property */
public double get_M12 ()

/** @property */
public void set_M12 (double value)

public function get M12 () : double

public function set M12 (value : double)

<object M12="double" .../>

Property Value

The value of the first row and second column of this Matrix. The default value is 0.

The following table shows the layout of a Matrix.










The following example shows how to multiply two Matrix structures and how to assign values to a Matrix when it is declared, and after the structure is declared.

private void multiplicationExample()

    Matrix matrix1 = new Matrix(5, 10, 15, 20, 25, 30);
    Matrix matrix2 = new Matrix(2, 4, 6, 8, 10, 12);
    // matrixResult is equal to (70,100,150,220,240,352) 
    Matrix matrixResult = Matrix.Multiply(matrix1, matrix2);
    // matrixResult2 is also
    // equal to (70,100,150,220,240,352) 
    Matrix matrixResult2 = matrix1 * matrix2;


Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0