Main Content

getTableCell

Class: Simulink.dialog.parameter.CustomTable
Package: Simulink.dialog.parameter

Get the properties of a custom table cell

Syntax

tableCell = tableControl.getTableCell([rowIdx colIdx])

Description

tableCell = tableControl.getTableCell([rowIdx colIdx]) gets the properties of a cell in a custom table.

Input Arguments

expand all

Handle to a custom table, specified as an object. You can use the getDialogControl command to get the custom table handle. For more information, see getDialogControl.

Consider, for example, tableControl = maskObj.getDialogControl(TableName). Here, maskObj is the mask object and TableName is the name of the custom table.

Data Types: numeric array

Row index number of the custom table cell for which the value is being fetched.

For example, '3'.

Column index number of the custom table cell for which the value is being fetched.

For example, '5'.

Output Arguments

expand all

Properties of the table cell, returned as a cell array.

Examples

% Get block mask handle.
maskObj = Simulink.Mask.get(gcb); 

% Get custom table handle.
tableControl = maskObj.getDialogControl('myTable');

% Get cell properties.
tableCell = tableControl.getTableCell( [2 2] ); 

tableCell = 

  CustomTableParamCellObject with properties:

          Value: 'Inherit'
           Type: 'popup'
        Enabled: 'off'
    TypeOptions: {4×1 cell}

tableCell.Value = 'Value'
Introduced in R2019a