rtLib — Notes Rich Text Management Library Documentation of rtLib — Notes Rich Text Management Library Download rtLib — Notes Rich Text Management Library FAQ of rtLib — Notes Rich Text Management Library Purchase rtLib — Notes Rich Text Management Library Feedback about rtLib — Notes Rich Text Management Library

Table manipulation

Special effects

Start search Mail feedback Back to Description

R5 tables allow extensive manipulation from user interface. Unfortunately many of these features are not available on Web. Most of them can be applied/modified using rtLib. Some samples:

Programmable tabbed table

With table

.rows (1).TabLabel = "Label 1"

.rows (2).TabLabel = "Label 2"

.Style.RowDisplay.Viewer = CDTABLEVIEWER_TABS

.Style.RowDisplay.TabsWithFieldDriven = True ' allows both programmatic and manual switching

.tableID = "robert" ' $robert will be field to set the selected tab

End With

' let's add a button that switches tabs

Dim button as new rtButton(0) ' click on button cycle through the tab labels

Set button.Label = new rtLabel("Cycle Tabs")

tabs=table.rows (1).TabLabel &"#" &table.rows (2).TabLabel

button.formula = |list:=@explode("| &tabs &|";"#"); | &_

|FIELD cnt:=@if(cnt="";@elements(list);@Modulo(cnt +1; @elements(list))+1);label:=@subset(@subset(list;cnt);-1); | &_

|FIELD $robert:=label;@Command([RefreshHideFormulas]);""|

ctx.add button

Dynamic display of the table

table.Style.RowDisplay.Viewer = CDTABLEVIEWER_ONLOADTIMER ' automatic

table.Style.RowDisplay.Transition = TRANS_ROLLING ' you may experiment with available values

table.Style.RowDisplay.Cycle = 1000 ' msec

Image resource as cell background

table.cells(1,1).Image = "dilbert.gif" ' use ImageFormula property to use calculated background image

table.cells(1,1).ImageDisplay = REPEAT_CENTER ' center it

Shadow and fancy borders

table.dropShadow = True ' quick way to get dropdown shadow (you may use also rtBorderStyle)

table.Style.Borders.DropShadowWidth = 20 ' use rtBorderStyle to elaborate or set shadow

table.Style.Borders.BorderWidths = 5

table.Style.Borders.BorderStyle = CDBORDERSTYLE_GROOVE ' whatever that means

For more complete code see different samples about table in Cookbook.