openoffice表格操作相关的一些宏例子
Sub Main
dim table as object
r_Tables = thiscomponent.getTextTables()
iCount = r_Tables.getCount
'msgbox iCount
tTableNames = r_Tables.getElementNames
for i = 0 to iCount-1
if tTableNames(i) = "table"then
table = r_Tables.getByName("table")
end if
next i
oTableCursor = table.createCursorByCellName("A1")
'oTableCursor.splitRange(2,true)
oTableCursor.goDown(2,true)
'oTableCursor.gotoCellByName("A3",true)
oTableCursor.splitRange(4,false)
End Sub