DynaPDF.Table.SetCellTable
--------------------------

Inserts a sub table into the specified cell.

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

MBS( "DynaPDF.Table.SetCellTable"; Table; Row; Col; HAlign; VAlign; SubTable ) 

**MBS**( **"DynaPDF.Table.SetCellTable";** /\* Inserts a sub table into the specified cell. \*/  
**$Table**; /\* The identifier for the table. \*/   
**$Row**; /\* The row number. Range from 0 to [DynaPDF.Table.GetNumRows](DynaPDFTableGetNumRows.md)-1.e.g. 0 \*/   
**$Col**; /\* The column number. Range from 0 to [DynaPDF.Table.GetNumCols](DynaPDFTableGetNumCols.md)-1.e.g. 0 \*/   
**$HAlign**; /\* The horizontal alignment. Can be left, center or right.e.g. "center" \*/   
**$VAlign**; /\* The vertical alignment. Can be bottom, center or top.e.g. "center" \*/   
**$SubTable**) /\* The identifier for the subtable. \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| Table | The identifier for the table. | $Table |
| Row | The row number. Range from 0 to [DynaPDF.Table.GetNumRows](DynaPDFTableGetNumRows.md)-1. | 0 |
| Col | The column number. Range from 0 to [DynaPDF.Table.GetNumCols](DynaPDFTableGetNumCols.md)-1. | 0 |
| HAlign | The horizontal alignment. Can be left, center or right. | "center" |
| VAlign | The vertical alignment. Can be bottom, center or top. | "center" |
| SubTable | The identifier for the subtable. | $SubTable |

### Result

Returns OK or error.

### Description

Inserts a sub table into the specified cell.   
A sub table is always a foreground object that has a strong width and height. That means, if the cell is not large enough then it will be expanded.  
Note that the function creates no copy of the table. But the plugin keeps a reference from subtable attached to parent table.   
### Examples

Sets a table to be used as content of a bigger table:

 MBS ("DynaPDF.Table.SetCellTable"; $table ; $row ; $col ; "left"; "top"; $subtable )  
### See also

- [DynaPDF.Table.GetNumCols](DynaPDFTableGetNumCols.md)
- [DynaPDF.Table.GetNumRows](DynaPDFTableGetNumRows.md)
- [DynaPDF.Table.SetCellAction](DynaPDFTableSetCellAction.md)
- [DynaPDF.Table.SetCellImage](DynaPDFTableSetCellImage.md)
- [DynaPDF.Table.SetCellImageEx](DynaPDFTableSetCellImageEx.md)
- [DynaPDF.Table.SetCellPadding](DynaPDFTableSetCellPadding.md)
- [DynaPDF.Table.SetCellSpacing](DynaPDFTableSetCellSpacing.md)
- [DynaPDF.Table.SetCellTemplate](DynaPDFTableSetCellTemplate.md)
- [DynaPDF.Table.SetCellText](DynaPDFTableSetCellText.md)
- [DynaPDF.Table.SetColWidth](DynaPDFTableSetColWidth.md)

### Example Databases

- [DynaPDF/Catalog with tables](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/DynaPDF/Catalog%20with%20tables.shtml#1ScriptAnchor_)
- [DynaPDF/Report](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/DynaPDF/Report.shtml#1ScriptAnchor_)

This function checks for a license.

Created 18th August 2014 , last changed 21st June 2021

  
[DynaPDF.Table.SetCellStyledText](DynaPDFTableSetCellStyledText.md) - [DynaPDF.Table.SetCellTemplate](DynaPDFTableSetCellTemplate.md)

[HTML Version](DynaPDFTableSetCellTable.shtml)