XL.Sheet.GetMarginRight
-----------------------

Returns the right margin of the sheet in inches.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [XL](component_XL.md) | [3.5](newinversion35.md) | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |

MBS( "XL.Sheet.GetMarginRight"; BookRef; SheetIndex ) 

**MBS**( **"XL.Sheet.GetMarginRight";** /\* Returns the right margin of the sheet in inches. \*/  
**$BookRef**; /\* The reference number for the workbook.e.g. $ref \*/   
**$SheetIndex**) /\* The index of the sheet. This number ranges from 0 to [XL.Book.SheetCount](XLBookSheetCount.md)-1.e.g. 0 \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| BookRef | The reference number for the workbook. | $ref |
| SheetIndex | The index of the sheet. This number ranges from 0 to [XL.Book.SheetCount](XLBookSheetCount.md)-1. | 0 |

### Result

Returns current margin value or error message.

### Description

Returns the right margin of the sheet in inches.  
### See also

- [XL.Book.SheetCount](XLBookSheetCount.md)
- [XL.Sheet.GetMarginBottom](XLSheetGetMarginBottom.md)
- [XL.Sheet.GetMarginLeft](XLSheetGetMarginLeft.md)
- [XL.Sheet.GetMarginTop](XLSheetGetMarginTop.md)
- [XL.Sheet.SetMarginLeft](XLSheetSetMarginLeft.md)
- [XL.Sheet.SetMarginRight](XLSheetSetMarginRight.md)
- [XL.Sheet.SetMarginTop](XLSheetSetMarginTop.md)

This function checks for a license.

Created 18th August 2014 , last changed 18th August 2014

  
[XL.Sheet.GetMarginLeft](XLSheetGetMarginLeft.md) - [XL.Sheet.GetMarginTop](XLSheetGetMarginTop.md)

[HTML Version](XLSheetGetMarginRight.shtml)