Topics   All   Mac OS X (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server (Not)   Client   Old   Guides   Examples
New in version: 6.3   6.4   6.5   7.0   7.1   7.2   7.3   7.4   7.5   7.6    Statistic  

DynaPDF.Table.AddRow

Adds a new row to the table.

Component Version macOS Windows Server FileMaker Cloud FileMaker iOS SDK
DynaPDF 3.5 Yes Yes Yes Yes Yes

MBS( "DynaPDF.Table.AddRow"; Table; Height )

Parameters

Parameter Description Example value
Table The identifier for the table. $Table
Height Minimum height or -1 for default height. 10

Result

Returns error or new row index.

Description

Adds a new row to the table.
The parameter Height can be set to a negative value to indicate that the default row height should be used. The default row height was specified in CreateTable().
The specified height represents the minumum height of the row. If the height of a foreground object is larger then the height will be adjusted.
The height is sometimes required. This is the case when a cell is rotated by 90 or a multiple of 90 degrees and if the height cannot be computed from the cell contents, e.g. if a cell contains text and if the flag NoLineBreak is absent. See DynaPDF.Table.SetCellOrientation for further information.

If the function succeeds, the return value is the row index, a value greater or equal zero. If the function fails, the return value is a negative error code.

Examples

Adds a row:

MBS("DynaPDF.Table.AddRow"; $table)

Adds a header row:

#Add header row
Set Variable [$row; Value:MBS("DynaPDF.Table.AddRow"; $table)]
Set Variable [$r; Value:MBS("DynaPDF.Table.SetCellText"; $table; $row; 0; "right"; "top"; "Index")]
Set Variable [$r; Value:MBS("DynaPDF.Table.SetCellText"; $table; $row; 1; "left"; "top"; "Product")]
Set Variable [$r; Value:MBS("DynaPDF.Table.SetCellText"; $table; $row; 2; "right"; "top"; "Price")]
Set Variable [$r; Value:MBS("DynaPDF.Table.SetCellText"; $table; $row; 3; "right"; "top"; "Quantity")]
Set Variable [$r; Value:MBS("DynaPDF.Table.SetCellText"; $table; $row; 4; "right"; "top"; "Total Price")]
# set flag for header row
Set Variable [$r; Value:MBS("DynaPDF.Table.SetFlags"; $table; $row; -1; "HeaderRow")]
# make row bold
Set Variable [$r; Value:MBS("DynaPDF.Table.SetFont"; $table; $row; -1; "Helvetica"; 2; 1; "unicode")]

See also

Example Databases


DynaPDF.Table.AddColumn   -   DynaPDF.Table.AddRows

Feedback: Report problem or ask question.




Links
MBS Xojo Plugins