Class

iOSCustomTableCell


Warning

This item was deprecated in version 2020r2. Please use MobileTableCustomCell as a replacement.

Description

An iOSCustomTableCell is a way to create a group of controls that can be embedded into a table cell. It is a great way to create powerful table layouts.

Events

Name

Parameters

Returns

AppearanceChanged

dark As Boolean

Close

Open

Property descriptions


iOSCustomTableCell.AccessibilityHint

AccessibilityHint As Text

The accessibility hint is a longer description that is read aloud when VoiceOver is enabled.

Me.AccessibilityHint = "Click to calculate the value and display the next view."

iOSCustomTableCell.AccessibilityLabel

AccessibilityLabel As Text

The accessibility label of of a control is a short name that is read aloud when VoiceOver is enabled.

Me.AccessibilityLabel = "Calculate the value."

iOSCustomTableCell.Height

Height As Double

The height of the control.

This property is read-only.


iOSCustomTableCell.Left

Left As Double

The left position of the control.

This property is read-only.


iOSCustomTableCell.Name

Name As Text

The name of the control. This can only be set in the Inspector. Use the name to refer to the control.

This property is read-only.


iOSCustomTableCell.Parent

Parent As iOSControl

Indicates the control's parent object, if it has one. If there is no parent, this is Nil.

This property is read-only.


iOSCustomTableCell.Top

Top As Double

The top position of the control.

This property is read-only.


iOSCustomTableCell.UseDynamicHeight

UseDynamicHeight As Boolean

Allows you to create cells which vary in height based on their content. The default value for this property is False to maintain backward compatibility.

Set this property to True to have the table's row height vary based on the custom cell inserted into it. This is useful if you have different sized custom cells you want to place in the table.

You can also dynamically change the custom cell's content to have the table row height change, but you'll want to change the autolayout constraint for the custom cell when it is added to the table.


iOSCustomTableCell.Visible

Visible As Boolean

Indicates whether the control is visible.

Make a button invisible:

Button1.Visible = False

iOSCustomTableCell.Width

Width As Double

The width of the control.

This property is read-only.

Method descriptions


iOSCustomTableCell.AddConstraint

AddConstraint(constraint As iOSLayoutConstraint)

Adds a constraint to the control. This constraint is used by child controls that have been added to this control.


iOSCustomTableCell.AddControl

AddControl(child As MobileControl)

Adds a child control to the control.


iOSCustomTableCell.Control

Control(index As Integer) As MobileControl

Gets the child control at the specified index.


iOSCustomTableCell.ControlCount

ControlCount As Integer

The number of child controls in the control.


iOSCustomTableCell.Handle

Handle As Ptr

The handle is used to get a reference to the control for interfacing directly with the iOS API.


iOSCustomTableCell.Invalidate

Invalidate

Marks the control so that it will be redrawn during the next event loop.

Call Invalidate to force a Canvas to redraw itself:

Canvas1.Invalidate

iOSCustomTableCell.RemoveConstraint

RemoveConstraint(constraint As iOSLayoutConstraint)

Removes a constraint from the control.


iOSCustomTableCell.RemoveControl

RemoveControl(child As MobileControl)

Removes the control from the control.


iOSCustomTableCell.SetTintColor

SetTintColor(value As Color)

Changes a control's tint color. This varies by control and for some controls may not do anything. For example, with an MobileTextField this changes the cursor color.

Event descriptions


iOSCustomTableCell.AppearanceChanged

AppearanceChanged(dark As Boolean)

Called when a user switches between Light and Dark mode.

Use this event to update any graphics or other UI as needed.


iOSCustomTableCell.Close

Close

Called when the control is removed from its container, such as a view.


iOSCustomTableCell.Open

Open

Called after the control is created. This is where you typically put initialization code.

Set label text in Open event:

Me.Text = "Hello"

Notes

To use, add a CustomTableCell to your project (drag it from the Library to the Navigator) and then drag the controls you want into it. You can then use it with the iOSTable.CreateCustomCell method in the table's data source RowData method or with the iOSTable.AddRow method.

Compatibility

iOS projects on the iOS operating system.

See also

MobileContainer parent class; iOSMobileTable control