The Item class gives access to items in Reporter. More...
The REPORTER JavaScript API provides many class constants, properties and methods. For Arup to
be able to extend and enhance the API in the future any constant, property or method names beginning with a lowercase
or uppercase letter are reserved.
If you need to add your own properties or methods to one of the existing classes then to avoid any potential future conflict you
should ensure that the name begins with either an underscore (_) or a dollar sign ($) or the name is prefixed with your
own unique identifier.
For example if company 'ABC' need to add a property called 'example' then to avoid any potential future conflict use one of:
| Name | Type | Description |
| active | logical | If item is active or not. Inactive items will be skipped during report/page/item generation. |
| autotableType | constant | Autotable type (whether the data is sourced from a file or a directory). Can be Reporter.AUTO_TABLE_DIRECTORY or Reporter.AUTO_TABLE_FILE. Valid for item type Item.AUTO_TABLE. |
| bottomCrop | integer | Bottom cropping value. Valid for item types Item.IMAGE, Item.IMAGE_FILE, Item.D3PLOT, Item.PRIMER and Item.THIS. |
| bottomMargin | real | Bottom margin width. Valid for item types Item.TEXTBOX, Item.TEXT_FILE, Item.TABLE and Item.AUTO_TABLE |
| columns (read only) | integer | The number of columns in the table. Valid for item types Item.TABLE and Item.AUTO_TABLE |
| conditions (read only) | integer | The number of conditions assigned to the item. Valid for item types Item.PROGRAM, Item.TEXT_FILE, Item.TEXT and Item.TEXTBOX |
| embed | logical | If image is embedded or not. Valid for item types Item.IMAGE |
| file | string | File or directory for item. Valid for item types: Item.AUTO_TABLE Item.D3PLOT Item.IMAGE Item.IMAGE_FILE Item.PRIMER Item.PROGRAM Item.SCRIPT_FILE Item.TEXT_FILE Item.THIS |
| filetype (read only) | string | Output file type. Read-only but can be updated by changing the file extension on the item property "file". Valid for item types Item.D3PLOT Item.PRIMER and Item.THIS. |
| fillColour | Colour object | Colour of fill for the item. Valid for item types Item.RECTANGLE, Item.ELLIPSE, Item.TEXTBOX, Item.PROGRAM and Item.TEXT_FILE |
| fontName | string | Font for the item e.g. "Courier". Can be any font accessible by REPORTER. Valid for item types Item.TEXT, Item.TEXTBOX, Item.PROGRAM and Item.TEXT_FILE |
| fontSize | integer | Font size for the item (6 <= fontSize <= 72). Valid for item types Item.TEXT, Item.TEXTBOX, Item.PROGRAM and Item.TEXT_FILE |
| fontStyle | constant | Font style for the item. Can be a combination of
Reporter.TEXT_NORMAL,
Reporter.TEXT_BOLD,
Reporter.TEXT_ITALIC or
Reporter.TEXT_UNDERLINE Valid for item types Item.TEXT, Item.TEXTBOX, Item.PROGRAM and Item.TEXT_FILE |
| generatedRowHeight | real | The height of each generated row in an Autotable. Valid for item type Item.AUTO_TABLE. |
| generating (read only) | logical | true if the item is currently being generated |
| headerHeight | real | The height of the header in an Autotable. Valid for item type Item.AUTO_TABLE. |
| height | real | Height for "rectangular" items (absolute difference between y and y2). Note that depending on what your object reference corner preference is set to, changing this property will result in different behaviour. |
| job | string | Input job file. Valid for item types Item.D3PLOT and Item.THIS. |
| justify | constant | Text justification for the item. Can be
Reporter.JUSTIFY_CENTRE,
Reporter.JUSTIFY_LEFT or
Reporter.JUSTIFY_RIGHT combined with
Reporter.JUSTIFY_TOP,
Reporter.JUSTIFY_MIDDLE or
Reporter.JUSTIFY_BOTTOM Valid for item types Item.TEXT, Item.TEXTBOX, Item.PROGRAM and Item.TEXT_FILE |
| leftCrop | integer | Left cropping value. Valid for item types Item.IMAGE, Item.IMAGE_FILE, Item.D3PLOT, Item.PRIMER and Item.THIS. |
| leftMargin | real | Left margin width. Valid for item types Item.TEXTBOX, Item.TEXT_FILE, Item.TABLE and Item.AUTO_TABLE |
| lineColour | Colour object | Colour of outline for the item. Valid for item types Item.LINE, Item.ARROW, Item.RECTANGLE, Item.ELLIPSE, Item.TEXTBOX, Item.D3PLOT, Item.PRIMER, Item.THIS, Item.PROGRAM, Item.TEXT_FILE, Item.IMAGE_FILE, Item.TABLE and Item.AUTO_TABLE. |
| lineStyle | constant | Style of outline for the item. Can be
Reporter.LINE_NONE,
Reporter.LINE_SOLID,
Reporter.LINE_DASH,
Reporter.LINE_DOT,
Reporter.LINE_DASH_DOT or
Reporter.LINE_DASH_DOT_DOT Valid for item types Item.LINE, Item.ARROW, Item.RECTANGLE, Item.ELLIPSE, Item.TEXTBOX, Item.D3PLOT, Item.PRIMER, Item.THIS, Item.PROGRAM, Item.TEXT_FILE and Item.IMAGE_FILE. |
| lineWidth | real | Width of outline for the item in mm. Valid for item types Item.LINE, Item.ARROW, Item.RECTANGLE, Item.ELLIPSE, Item.TEXTBOX, Item.D3PLOT, Item.PRIMER, Item.THIS, Item.PROGRAM, Item.TEXT_FILE, Item.IMAGE_FILE, Item.TABLE and Item.AUTO_TABLE |
| name | string | Name of the Item |
| resolution | integer | Image resolution. Larger values yield a smaller image representation on screen. Valid for item type Item.IMAGE. |
| rightCrop | integer | Right cropping value. Valid for item types Item.IMAGE, Item.IMAGE_FILE, Item.D3PLOT, Item.PRIMER and Item.THIS. |
| rightMargin | real | Right margin width. Valid for item types Item.TEXTBOX, Item.TEXT_FILE, Item.TABLE and Item.AUTO_TABLE |
| rows (read only) | integer | The number of rows in the table. Valid for item type Item.TABLE |
| saveCSV | bool | Whether or not a CSV file of the table contents is written when the item is generated. Valid for item types Item.TABLE and Item.AUTO_TABLE |
| saveCSVFilename | string | The path and filename of the CSV file written when the item is generated. Valid for item types Item.TABLE and Item.AUTO_TABLE |
| saveXlsx | bool | Whether or not a Excel file of the table contents is written when the item is generated. Valid for item types Item.TABLE and Item.AUTO_TABLE |
| saveXlsxFilename | string | The path and filename of the Excel file written when the item is generated. Valid for item types Item.TABLE and Item.AUTO_TABLE |
| script | string | The script source text for the item. Only valid for item type Item.SCRIPT. For Item.SCRIPT_FILE, use the file property. |
| text | string | The text for the item. Valid for item types Item.TEXT, Item.TEXTBOX, Item.PROGRAM, Item.TEXT_FILE and Item.SCRIPT |
| textColour | Colour object | Colour of text for the item. Valid for item types Item.TEXT, Item.TEXTBOX, Item.PROGRAM and Item.TEXT_FILE |
| topCrop | integer | Top cropping value. Valid for item types Item.IMAGE, Item.IMAGE_FILE, Item.D3PLOT, Item.PRIMER and Item.THIS. |
| topMargin | real | Top margin width. Valid for item types Item.TEXTBOX, Item.TEXT_FILE, Item.TABLE and Item.AUTO_TABLE |
| type (read only) | constant | type of the Item. Can be Item.LINE, Item.TEXT etc. |
| width | real | Width for "rectangular" items (absolute difference between x and x2). Note that depending on what your object reference corner preference is set to, changing this property will result in different behaviour. |
| x | real | X coordinate |
| x2 | real | Second X coordinate for "rectangular" items |
| y | real | Y coordinate |
| y2 | real | Second Y coordinate for "rectangular" items |
Detailed DescriptionThe Item class allows you to access the items in templates that Reporter currently has open. |
Constructornew Item(page[Page], type[constant], name (optional)[string], x (optional)[real], x2 (optional)[real], y (optional)[real], y2 (optional)[real])DescriptionCreate a new Item. The name and coordinates arguments are optional. Item.TABLE items are constructed with two rows and two columns by default. If you require only one row or column, use DeleteRow and DeleteColumn. |
Page to create item in
Item type. Can be Item.LINE, Item.ARROW, Item.RECTANGLE, Item.ELLIPSE, Item.TEXT, Item.TEXTBOX, Item.IMAGE, Item.PROGRAM, Item.D3PLOT, Item.PRIMER, Item.THIS, Item.TEXT_FILE, Item.IMAGE_FILE, Item.LIBRARY_IMAGE, Item.LIBRARY_PROGRAM, Item.TABLE, Item.AUTO_TABLE, Item.SCRIPT, Item.SCRIPT_FILE, Item.NOTE or Item.PLACEHOLDER.
Name of item
X coordinate
Second X coordinate for "rectangular" items
Y coordinate
Second Y coordinate for "rectangular" items
ReturnsItem object Return typeItem |
ExampleTo create a new blank Item object: var i = new Item();
|
Details of functionsDeleteColumn(column[integer])DescriptionDelete a column from a table. Valid for item type Item.TABLE and Item.AUTO_TABLE. |
The index of the column to delete. Note that indices start from 0.
ReturnsNo return value |
ExampleTo delete the second column from table item i: i.DeleteColumn(1);
|
DeleteRow(row[integer])DescriptionDelete a row from a table. Valid for item type Item.TABLE. |
The index of the row to delete. Note that indices start from 0.
ReturnsNo return value |
ExampleTo delete the second row from table item i: i.DeleteRow(1);
|
Generate()DescriptionGenerate an item. |
No arguments
ReturnsNo return value |
ExampleTo generate item i: i.Generate();
|
GetAll(page[Page]) [static]DescriptionGet all of the items on a page. |
Page to get items from.
ReturnsArray of Item objects Return typeArray |
ExampleTo get all of the items on page p: var items = Item.GetAll(p);
|
GetCellProperties(row[integer], column[integer])DescriptionGet the properties of the specified cell. Valid for item type Item.TABLE. |
The row index of the cell of interest. Note that indices start from 0.
The column index of the cell of interest. Note that indices start from 0.
Returns |
Object with the following properties:
| Name | Type | Description |
| bottomBorderWidth | real | Cell bottom border width. Can be 0.0, 0.1, 0.5, 0.75, 1.0, 1.5, 2.0, 2.5, 3.0, 4.0, 5.0. Other values will result in no border. |
| colspan | integer | Number of columns this cell spans (for merged cells). 1 if not merged. Use columnMergeOrigin to find top-left cell. |
| column | integer | The column index |
| columnMergeOrigin | integer | The column index of the top-left cell in this merge cell group (if cell not merged then == column). |
| conditions | integer | Number of conditions assigned to this cell. |
| fillColour | Colour object | Fill colour |
| fontName | string | Font name (e.g. "Courier"). |
| fontSize | integer | Font size (between 6 and 72). |
| fontStyle | integer | Font style. See Text style constants for details. |
| height | real | Cell height. Modifying this property will modify the height of all cells in the row. |
| hyperlinkHTML | string | Hyperlink destination for HTML. |
| hyperlinkPDF | string | Hyperlink destination for PDF. |
| hyperlinkReport | string | Hyperlink destination for Report or page within Report. |
| justify | integer | Text justification for the item. Same rules as justify property of Item Class. |
| output | string | The output text from a Program or Library Program cell. |
| prefix | string | Prefix text to appear before Library Program output. |
| program | string | Path and filename for a Program cell, or the filename (e.g. title.js) for a Library Program cell. |
| programArgs | Array of strings | Program arguments |
| rightBorderWidth | real | Cell right border width. Can be 0.0, 0.1, 0.5, 0.75, 1.0, 1.5, 2.0, 2.5, 3.0, 4.0, 5.0. Other values will result in no border. |
| row | integer | The cell row index. |
| rowMergeOrigin | integer | The row index of the top-left cell in this merge cell group (if cell not merged then == row). |
| rowSpan | integer | Number of rows this cell spans (for merged cells). == 1 if not merged. Use rowMergeOrigin to find top-left cell. |
| suffix | string | Suffix text to appear after Library Program output. |
| text | string | The cell text. For Program and Library Program cells, use the prefix, output and suffix properties. |
| textColour | Colour object | Colour of text |
| topBorderWidth | real | Cell top border width. Can be 0.0, 0.1, 0.5, 0.75, 1.0, 1.5, 2.0, 2.5, 3.0, 4.0, 5.0. Other values will result in no border. |
| type | integer | Can be Item.TEXT,Item.LIBRARY_PROGRAM or Item.PROGRAM. |
| variable | string | REPORTER variable for library program output. |
| width | real | Cell width. Modifying this property will modify the width of all cells in the column. |
object
ExampleTo get the properties of the top-left cell in a table: i.GetCellProperties(0, 0);
|
GetColumnProperties(column[integer], header[constant])DescriptionGet an autotable column properties. Valid for item type Item.AUTO_TABLE. |
The index of the column of interest. Note that indices start from 0.
An argument to signify to get the properties of the header or the generated rows. Can be Reporter.AUTO_TABLE_HEADER or Reporter.AUTO_TABLE_ROWS.
Returns |
Object with the following properties:
| Name | Type | Description |
| conditions | integer | Number of conditions assigned to this cell. |
| fillColour | Colour object | Fill colour |
| fontName | string | Font name (e.g. "Courier"). |
| fontSize | integer | Font size (between 6 and 72). |
| fontStyle | integer | Font style. Same rules as fontStyle property of |
| hyperlinkHTML | string | Hyperlink destination for HTML. |
| hyperlinkPDF | string | Hyperlink destination for PDF. |
| hyperlinkReport | string | Hyperlink destination for Report or page within Report. |
| justify | integer | Text justification for the item. Same rules as justify property of Item Class. |
| program | string | Path and filename for a Program cell, or the filename (e.g. title.js) for a Library Program cell. |
| programArgs | Array of strings | Program arguments |
| text | string | The cell text. For Program and Library Program cells, use the prefix, output and suffix properties. |
| textColour | Colour object | Colour of text |
| type | integer | Can be Item.TEXT,Item.LIBRARY_PROGRAM or Item.PROGRAM. |
| width | real | Cell width. Modifying this property will modify the width of all cells in the column. |
object
ExampleReturns the column properties of the header of the first column: i.GetColumnProperties(0, Reporter.AUTO_TABLE_HEADER);
|
GetColumnWidth(row[integer])DescriptionGet the width of a table column. Valid for item types Item.TABLE or Item.AUTO_TABLE. |
The index of the column of interest. Note that indices start from 0.
ReturnsInteger. The width of the specified column. Return typeNumber |
ExampleTo get the width of the first column in a table: i.GetColumnWidth(0);
|
GetCondition(index[integer])DescriptionGet the conditional formatting data for an item. Valid for item types Item.TEXT_FILE, Item.PROGRAM, Item.TEXT or Item.TEXTBOX (for Item.AUTO_TABLE and Item.TABLE, see GetCondition functions with additional arguments below). |
The index of the condition to get. Note that indices start from 0. See conditions for the total number of comditions
Returns |
Object with the following properties:
| Name | Type | Description |
| fillColour | Colour object | Fill colour |
| fontName | string | Font name (e.g. "Courier"). |
| fontSize | integer | Font size (between 6 and 72). |
| fontStyle | integer | Font style. See Text style constants for details. |
| justify | integer | Text alignment for the item. See Justification constants for details. |
| name | string | Condition name |
| textColour | Colour object | Colour of text |
| type | integer | See Condition types constants for details. |
| value | string | First condition value |
| value2 | string | Second condition value (where relevant) |
object
ExampleTo get the data for the 2nd condition in item i: var condition = i.GetCondition(1);
|
GetCondition(index[integer], column[integer])DescriptionGet the conditional formatting data for an Item.AUTO_TABLE item. |
The index of the condition to get. Note that indices start from 0.
The column to get the condition from. Note that indices start from 0.
Returns |
Object with the following properties:
| Name | Type | Description |
| fillColour | Colour object | Fill colour |
| fontName | string | Font name (e.g. "Courier"). |
| fontSize | integer | Font size (between 6 and 72). |
| fontStyle | integer | Font style. See Text style constants for details. |
| justify | integer | Text alignment for the item. See Justification constants for details. |
| name | string | Condition name |
| textColour | Colour object | Colour of text |
| type | integer | See Condition types constants for details. |
| value | string | First condition value |
| value2 | string | Second condition value (where relevant) |
object
ExampleTo get the data for the 2nd condition from the 3rd column in autotable item i: var condition = i.GetCondition(1, 2);
|
GetCondition(index[integer], row[integer], column[integer])DescriptionGet the conditional formatting data for an Item.TABLE item. |
The index of the condition to get. Note that indices start from 0.
The cell row to get the condition from. Note that indices start from 0.
The cell column to get the condition from. Note that indices start from 0.
Returns |
Object with the following properties:
| Name | Type | Description |
| fillColour | Colour object | Fill colour |
| fontName | string | Font name (e.g. "Courier"). |
| fontSize | integer | Font size (between 6 and 72). |
| fontStyle | integer | Font style. See Text style constants for details. |
| justify | integer | Text alignment for the item. See Justification constants for details. |
| name | string | Condition name |
| textColour | Colour object | Colour of text |
| type | integer | See Condition types constants for details. |
| value | string | First condition value |
| value2 | string | Second condition value (where relevant) |
object
ExampleTo get the data for the 2nd condition from the 4th row, 3rd column in table item i: var condition = i.GetCondition(1, 3, 2);
|
GetFromName(page[Page], name[string]) [static]DescriptionGet an Item from its name. |
Page to get item from
Item name
ReturnsItem object (or null if item cannot be found) Return typeItem |
ExampleTo get the item with name test on page p: var item = Item.GetFromName(p, "test");
|
GetGeneratedData(row_index[integer], column_index[integer])DescriptionGet the text that appears in an autotable cell once generated. Valid for item type Item.AUTO_TABLE. |
The index of the row of interest. Note that indices start from 0.
The index of the column of interest. Note that indicies start from 0.
ReturnsString: the text displayed in the specified row and column. Return typeString |
ExampleGet the data from the first cell in the first row and column in an autotable. i.GetGeneratedData(0, 0);
|
GetRowHeight(row[integer])DescriptionGet the height of a table row. Valid for item type Item.TABLE. |
The index of the row of interest. Note that indices start from 0.
Returnsinteger Return typeNumber |
ExampleTo get the height of the first row in a table: i.GetRowHeight(0);
|
InsertColumn(column[integer])DescriptionInsert a column into a table. Valid for item types Item.TABLE and Item.AUTO_TABLE. |
The index of the position where the inserted column will end up. Note that indices start from 0. If no argument is given, a column will be added to the bottom of the table.
ReturnsNo return value |
ExampleTo insert a column that will become the second column from the left of the table: i.InsertColumn(1);
|
InsertRow(row[integer])DescriptionInsert a row into a table. Valid for item type Item.TABLE. |
The index of the position where the inserted row will end up. Note that indices start from 0. If no argument is given, a row will be added to the bottom of the table.
ReturnsNo return value |
ExampleTo insert a row that will become the second row from the top of the table: i.InsertRow(1);
|
MergeCells(topLeftRow[integer], topLeftColumn[integer], rows[integer], columns[integer])DescriptionMerge specified cells in a table. Valid for item types Item.TABLE and Item.AUTO_TABLE. |
The row index of the top-left cell in the group of cells to be merged. Note that indices start from 0.
The column index of the top-left cell in the group of cells to be merged. Note that indices start from 0.
The number of rows of cells to be merged (measured from the topLeftRow position).
The number of columns of cells to be merged (measured from the topLeftColumn position).
ReturnsNo return value |
ExampleTo merge the cells in first row and the first two columns in the table: i.MergeCells(0, 0, 1, 2);
|
RemoveCondition(condition[integer])DescriptionRemove the specified condition for an item. Valid for item types Item.TEXT_FILE, Item.PROGRAM, Item.TEXT or Item.TEXTBOX (for Item.AUTO_TABLE and Item.TABLE, see RemoveCondition functions with additional arguments below). |
The index of the condition you wish to remove. Note that indices start at 0.
ReturnsNo return value |
ExampleTo remove the condition for the condition index 1 in item i: i.RemoveCondition(1);
|
RemoveCondition(condition[integer], column[integer])DescriptionRemove the specified condition for an Item.AUTO_TABLE item. |
The index of the condition you wish to remove. Note that indices start at 0.
The column to remove the condition for. Note that indices start from 0.
ReturnsNo return value |
ExampleTo remove the condition for condition index 1 in the third column in item i: i.RemoveCondition(1, 2);
|
RemoveCondition(condition[integer], row[integer], column[integer])DescriptionRemove the specified condition for an Item.TABLE item. |
The index of the condition you wish to remove. Note that indices start at 0.
The row to remove the condition for. Note that indices start from 0.
The column to remove the condition for. Note that indices start from 0.
ReturnsNo return value |
ExampleTo remove the condition for condition index 1 in the fourth row, third column in item i: i.RemoveCondition(1, 3, 2);
|
SetCellProperties(properties[object], row[integer], column[integer])DescriptionSet the properties of the specified cell. Valid for item type Item.TABLE. |
An object containing the cell properties.
Object has the following properties:
| Name | Type | Description |
| bottomBorderWidth (optional) | real | Cell bottom border width. Can be 0.0, 0.1, 0.5, 0.75, 1.0, 1.5, 2.0, 2.5, 3.0, 4.0, 5.0. Other values will result in no border. |
| fillColour (optional) | Colour object | Fill colour |
| fontName (optional) | string | Font name (e.g. "Courier"). |
| fontSize (optional) | integer | Font size (between 6 and 72). |
| fontStyle (optional) | integer | Font style. See Text style constants for details. |
| hyperlinkHTML (optional) | string | Hyperlink destination for HTML. |
| hyperlinkPDF (optional) | string | Hyperlink destination for PDF. |
| hyperlinkReport (optional) | string | Hyperlink destination for Report or page within Report. |
| justify (optional) | integer | Text justification for the item. Same rules as justify property of Item Class. |
| prefix (optional) | string | Prefix text to appear before Library Program output. |
| program (optional) | string | Path and filename for a Program cell, or the filename (e.g. title.js) for a Library Program cell. |
| programArgs (optional) | Array of strings | Program arguments |
| rightBorderWidth (optional) | real | Cell right border width. Can be 0.0, 0.1, 0.5, 0.75, 1.0, 1.5, 2.0, 2.5, 3.0, 4.0, 5.0. Other values will result in no border. |
| suffix (optional) | string | Suffix text to appear after Library Program output. |
| text (optional) | string | The cell text. For Program and Library Program cells, use the prefix, output and suffix properties. |
| textColour (optional) | Colour object | Colour of text |
| topBorderWidth (optional) | real | Cell top border width. Can be 0.0, 0.1, 0.5, 0.75, 1.0, 1.5, 2.0, 2.5, 3.0, 4.0, 5.0. Other values will result in no border. |
| type (optional) | integer | Can be Item.TEXT,Item.LIBRARY_PROGRAM or Item.PROGRAM. |
| variable (optional) | string | REPORTER variable for library program output. |
The row index of the cell to be modified. Note that indices start from 0.
The column index of the cell to be modified. Note that indices start from 0.
ReturnsNo return value |
ExampleTo set the properties of the cell object to those of the object cell_obj: i.SetCellProperties(cell_obj, 0, 0);
|
SetColumnProperties(properties[object], column[integer], header[constant])DescriptionSet the properties of an autotable column. Valid for item type Item.AUTO_TABLE. |
Set the properties of an autotable column. Valid for item type Item.AUTO_TABLE.
Object has the following properties:
| Name | Type | Description |
| fillColour (optional) | Colour object | Fill colour |
| fontName (optional) | string | Font name (e.g. "Courier"). |
| fontSize (optional) | integer | Font size (between 6 and 72). |
| fontStyle (optional) | integer | Font style. Same rules as fontStyle property of |
| hyperlinkHTML (optional) | string | Hyperlink destination for HTML. |
| hyperlinkPDF (optional) | string | Hyperlink destination for PDF. |
| hyperlinkReport (optional) | string | Hyperlink destination for Report or page within Report. |
| justify (optional) | integer | Text justification for the item. Same rules as justify property of Item Class. |
| program (optional) | string | Path and filename for a Program cell, or the filename (e.g. title.js) for a Library Program cell. |
| programArgs (optional) | Array of strings | Program arguments |
| text (optional) | string | The cell text. For Program and Library Program cells, use the prefix, output and suffix properties. |
| textColour (optional) | Colour object | Colour of text |
| type (optional) | integer | Can be Item.TEXT,Item.LIBRARY_PROGRAM or Item.PROGRAM. |
The index of the column of interest. Note that indices start from 0.
An argument to signify to set the properties of the header or the generated rows. Can be Reporter.AUTO_TABLE_HEADER or Reporter.AUTO_TABLE_ROWS.
ReturnsNo return value |
ExampleSets the column properties of the header of the first column with the properties of the object column_obj. i.SetColumnProperties(column_obj, 0, Reporter.AUTO_TABLE_HEADER);
|
SetColumnWidth(column[integer], width[real])DescriptionSet the width of a table column. Valid for item type Item.TABLE. |
The index of the column of interest. Note that indices start from 0.
The column width.
ReturnsNo return value |
ExampleTo set the width of the first column in a table to 10.0: i.SetColumnWidth(0, 10.0);
|
SetCondition(condition[integer], properties[object])DescriptionSet the specified condition for an item. Valid for item types Item.TEXT_FILE, Item.PROGRAM, Item.TEXT or Item.TEXTBOX (for Item.AUTO_TABLE and Item.TABLE, see SetCondition functions with additional arguments below). |
The index of the condition you wish to set. Note that indices start at 0. If a condition already exists at the specified index, it will be replaced. To add a new condition, specify an index equal to the number of existing conditions.
The index of the condition you wish to set. Note that indices start at 0. If a condition already exists at the specified index, it will be replaced. To add a new condition, specify an index equal to the number of existing conditions.
Object has the following properties:
| Name | Type | Description |
| fillColour (optional) | Colour object | Fill colour |
| fontName (optional) | string | Font name (e.g. "Courier"). |
| fontSize (optional) | integer | Font size (between 6 and 72). |
| fontStyle (optional) | integer | Font style. See Text style constants for details. |
| justify (optional) | integer | Text alignment for the item. See Justification constants for details. |
| name | string | Condition name |
| textColour (optional) | Colour object | Colour of text |
| type (optional) | integer | See Condition types constants for details. |
| value (optional) | string | First condition value |
| value2 (optional) | string | Second condition value (where relevant) |
ReturnsNo return value |
SetCondition(condition[integer], column[integer], properties[object])DescriptionSet the specified condition for an Item.AUTO_TABLE item. |
The index of the condition you wish to set. Note that indices start at 0. If a condition already exists at the specified index, it will be replaced. To add a new condition, specify an index equal to the number of existing conditions.
The column to set the condition for. Note that indices start from 0.
The column to set the condition for. Note that indices start from 0.
Object has the following properties:
| Name | Type | Description |
| fillColour (optional) | Colour object | Fill colour |
| fontName (optional) | string | Font name (e.g. "Courier"). |
| fontSize (optional) | integer | Font size (between 6 and 72). |
| fontStyle (optional) | integer | Font style. See Text style constants for details. |
| justify (optional) | integer | Text alignment for the item. See Justification constants for details. |
| name | string | Condition name |
| textColour (optional) | Colour object | Colour of text |
| type (optional) | integer | See Condition types constants for details. |
| value (optional) | string | First condition value |
| value2 (optional) | string | Second condition value (where relevant) |
ReturnsNo return value |
SetCondition(condition[integer], row[integer], column[integer], properties[object])DescriptionSet the specified condition for an Item.TABLE item. |
The index of the condition you wish to set. Note that indices start at 0. If a condition already exists at the specified index, it will be replaced. To add a new condition, specify an index equal to the number of existing conditions.
The row to set the condition for. Note that indices start from 0.
The column to set the condition for. Note that indices start from 0.
The column to set the condition for. Note that indices start from 0.
Object has the following properties:
| Name | Type | Description |
| fillColour (optional) | Colour object | Fill colour |
| fontName (optional) | string | Font name (e.g. "Courier"). |
| fontSize (optional) | integer | Font size (between 6 and 72). |
| fontStyle (optional) | integer | Font style. See Text style constants for details. |
| justify (optional) | integer | Text alignment for the item. See Justification constants for details. |
| name | string | Condition name |
| textColour (optional) | Colour object | Colour of text |
| type (optional) | integer | See Condition types constants for details. |
| value (optional) | string | First condition value |
| value2 (optional) | string | Second condition value (where relevant) |
ReturnsNo return value |
SetRowHeight(row[integer], height[real])DescriptionSet the height of a table row. Valid for item type Item.TABLE and Item.AUTO_TABLE. |
The index of the row of interest. Note that indices start from 0.
The row height.
ReturnsNo return value |
ExampleTo set the height of the first row in a table to 10.0: i.SetRowHeight(0, 10.0);
|
UnmergeCells(row[integer], column[integer])DescriptionUnmerge the specified cell in a table. All cells merged to the specified cell will be unmerged. Valid for item types Item.TABLE and Item.AUTO_TABLE. |
The row index of the cell to be unmerged. Note that indices start from 0.
The column index of the cell to be unmerged. Note that indices start from 0..
ReturnsNo return value |
ExampleTo unmerge the top-left cell in a table: i.UnmergeCells(0, 0);
|