21.08.2013 Views

OpenOffice.org BASIC Guide.pdf - OpenOffice.org wiki

OpenOffice.org BASIC Guide.pdf - OpenOffice.org wiki

OpenOffice.org BASIC Guide.pdf - OpenOffice.org wiki

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

More Than Just Text 109<br />

Next I<br />

Text tables are available in <strong>OpenOffice</strong>.<strong>org</strong> through the TextTables list of the document object. The<br />

previous example shows how a text table can be created. The options for accessing text tables are<br />

described in the following section.<br />

Editing Tables<br />

A table consists of individual rows. These in turn contain the various cells. Strictly<br />

speaking, there are no table columns in <strong>OpenOffice</strong>.<strong>org</strong>. These are produced implicitly by<br />

arranging the rows (one under another) next to one another. To simplify access to the<br />

tables, <strong>OpenOffice</strong>.<strong>org</strong>, however, provides some methods which operate using columns.<br />

These are useful if no cells have been merged in the table.<br />

Let us first take the properties of the table itself. These are defined in the<br />

com.sun.star.text.TextTable<br />

service. Here is an list of the most important properties of the table object:<br />

BackColor (Long)<br />

background color of table.<br />

BottomMargin (Long)<br />

bottom margin in 100ths of a millimeter.<br />

LeftMargin (Long)<br />

left margin in 100ths of a millimeter.<br />

RightMargin (Long)<br />

right margin in 100ths of a millimeter.<br />

TopMargin (Long)<br />

top margin in 100ths of a millimeter.<br />

RepeatHeadline (Boolean)<br />

table header is repeated on every page.<br />

Width (Long)<br />

Rows<br />

absolute width of the table in 100ths of a millimeter.<br />

A table consists of a list containing rows. The following example shows how the rows of a<br />

table can be retrieved and formatted.<br />

Dim Doc As Object<br />

Dim Table As Object<br />

Dim Cursor As Object<br />

Dim Rows As Object<br />

Dim Row As Object<br />

Dim I As Integer

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!