Matrix.Resize
-------------

Resizes matrix to given height and width.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [Matrix](component_Matrix.md) | [9.2](newinversion92.md) | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |

MBS( "Matrix.Resize"; MatrixRef; Height; Width ) 

**MBS**( **"Matrix.Resize";** /\* Resizes matrix to given height and width. \*/  
**$MatrixRef**; /\* The matrix reference number.e.g. $matrix \*/   
**$Height**; /\* The height of the matrix.e.g. 3 \*/   
**$Width**) /\* The width of the matrix.e.g. 4 \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| MatrixRef | The matrix reference number. | $matrix |
| Height | The height of the matrix. | 3 |
| Width | The width of the matrix. | 4 |

### Result

Returns OK or error.

### Description

Resizes matrix to given height and width.  
### Examples

Try resize:

 Set Variable \[ $matrix ; Value: MBS ( "[Matrix.New](MatrixNew.md)"; 3; 4 ) \]   
Set Variable \[ $r ; Value: MBS ( "Matrix.Resize"; $matrix ; 7; 8 ) \]   
Show Custom Dialog \[ "Size" ; MBS ( "[Matrix.Width](MatrixWidth.md)"; $matrix ) &amp; " x " &amp; MBS ( "[Matrix.Height](MatrixHeight.md)"; $matrix ) \]   
Set Variable \[ $r ; Value: MBS ( "[Matrix.Release](MatrixRelease.md)"; $matrix ) \]  
Resizes a matrix:

 Set Variable \[ $r ; Value: MBS ( "Matrix.Resize"; $matrix ; 3; 4 ) \]  
### See also

- [Matrix.Height](MatrixHeight.md)
- [Matrix.New](MatrixNew.md)
- [Matrix.Release](MatrixRelease.md)
- [Matrix.Width](MatrixWidth.md)

This function checks for a license.

Created 8th April 2019 , last changed 2nd November 2020

  
[Matrix.RemoveRow](MatrixRemoveRow.md) - [Matrix.Rotate](MatrixRotate.md)

[HTML Version](MatrixResize.shtml)