XL.Book.GetPicture
------------------

Returns a picture at position index.

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

MBS( "XL.Book.GetPicture"; BookRef; Index ) 

**MBS**( **"XL.Book.GetPicture";** /\* Returns a picture at position index. \*/  
**$BookRef**; /\* The reference number for the workbook.e.g. $ref \*/   
**$Index**) /\* The index of the picture from 0 to [XL.Book.PictureCount](XLBookPictureCount.md)-1.e.g. 0 \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| BookRef | The reference number for the workbook. | $ref |
| Index | The index of the picture from 0 to [XL.Book.PictureCount](XLBookPictureCount.md)-1. | 0 |

### Result

Returns image or error.

### Description

Returns a picture at position index.  
Returns container value with file, jpeg, gif, tiff or png.  
Please use [XL.Book.GetPictureType](XLBookGetPictureType.md) to know the picture type before or [Container.GetName](ContainerGetName.md) and [Container.GetTypes](ContainerGetTypes.md) after.  
### Examples

Query picture of a cell:

 Set Variable \[ $sheet ; Value: 0 \]   
Set Variable \[ $row ; Value: 2 \]   
Set Variable \[ $col ; Value: 3 \]   
Set Variable \[ $index ; Value: MBS ( "[XL.Sheet.GetCellPicture](XLSheetGetCellPicture.md)"; $bookRef ; $sheet ; $row ; $col ) \]   
Set Field \[ XL::test ; MBS ( "XL.Book.GetPicture"; $bookRef ; $index ) \]  
### See also

- [Container.GetName](ContainerGetName.md)
- [Container.GetType](ContainerGetType.md)
- [Container.GetTypes](ContainerGetTypes.md)
- [XL.Book.GetPictureType](XLBookGetPictureType.md)
- [XL.Book.PictureCount](XLBookPictureCount.md)
- [XL.Sheet.GetCellPicture](XLSheetGetCellPicture.md)
- [XL.Sheet.GetPicture](XLSheetGetPicture.md)

### Release notes

- **Version 14.2**
    - Added SVG for [XL.Book.GetPictureType](https://www.mbsplugins.eu/XLBookGetPictureType.shtml) and [XL.Book.GetPicture](https://www.mbsplugins.eu/XLBookGetPicture.shtml).
    - Added work around for [XL.Book.GetPicture](https://www.mbsplugins.eu/XLBookGetPicture.shtml) to return image data, even if LibXL returns an error, but does provide data.
    - Improved [XL.Book.GetPicture](https://www.mbsplugins.eu/XLBookGetPicture.shtml) to return future pictures types as FILE containers.
    - Improved [XL.Book.GetPictureType](https://www.mbsplugins.eu/XLBookGetPictureType.shtml) to report future types as number.

### Example Databases

- [XL/XL Test](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/XL/XL%20Test.shtml#6ScriptAnchor_)

### Blog Entries

- [Neues MBS Plugin 14.2 für Claris FileMaker](https://www.mbsplugins.de/archive/2024-05-14/Neues_MBS_Plugin_142_für_Clar/monkeybreadsoftware_blog_filemaker)
- [MBS Plugin 14.2 for Claris FileMaker](https://www.mbsplugins.de/archive/2024-05-14/MBS_Plugin_142_for_Claris_File/monkeybreadsoftware_blog_filemaker)
- [MBS FileMaker Plugin, version 14.2pr2](https://www.mbsplugins.de/archive/2024-04-11/MBS_FileMaker_Plugin_version_1/monkeybreadsoftware_blog_filemaker)
- [New in version 11.5 of MBS FileMaker Plugin](https://www.mbsplugins.de/archive/2021-11-30/New_in_version_115_of_MBS_File/monkeybreadsoftware_blog_filemaker)
- [LibXL for FileMaker with extras](https://www.mbsplugins.de/archive/2021-03-02/LibXL_for_FileMaker_with_extra/monkeybreadsoftware_blog_filemaker)

### FileMaker Magazin

- [Ausgabe 1/2025, Seite 29](https://filemaker-magazin.de/neuigkeit/4282-Appetithappen-FMM_202501)

This function checks for a license.

Created 18th August 2014 , last changed 5th April 2024

  
[XL.Book.GetDefaultFontSize](XLBookGetDefaultFontSize.md) - [XL.Book.GetPictureType](XLBookGetPictureType.md)

[HTML Version](XLBookGetPicture.shtml)