Dim table As New rtTable(2, 4)
Dim i As Integer, j As Integer

Dim font As New rtfontstyle(0)
Dim img As rtGraphic

Set table.Style = New rtStyle (0)
Set table.Style.RowDisplay = New rtRowDisplayStyle (0)
table.Style.RowDisplay.Viewer = CDTABLEVIEWER_TABS
Set table.LayoutStyle = New rtTableStyle (0)
table.LayoutStyle.LeftMargin = 3*ONE_CM

Set font.Color = New rtColor(COLOR_RED)

For i =1 To table.rowCount
 table.rows(i).TabLabel = "R" &i
 For j=1 To table.ColumnCount
  With table.cells(i,j)
   Set .Color = New rtColor(0)
   ' some random color
   .Color.setRGB (10000*Rnd) Mod 255, (10000*Rnd) Mod 255, (10000*Rnd) Mod 255
   Set img = New rtGraphic("c:\temp\denmarkf.gif") ' make sure you have some image there
   .appendstyle font
   .appendText "cell " &i &"x" &j
   .add img
   .addNewline 1
  End With
  table.columns(j).CellWidth=one_CM
 Next
Next

ctxDump.addNewLine 1
ctxDump.add table
ctxDump.addNewLine 1
|