1

I have a table with the Property: Name = 'Images'.
I want to write a check if my ViewCursor is present in this table or not.
You can get the location of the ViewCursor with this code:

vViewCursor = ThisComponent.getCurrentController().getViewCursor() 

But I don't know how to check whether the vViewCursor is in the table: 'Images' or not.
Does anyone have an idea how to do that?

I wrote macros in Openoffice Basic. The table is in OpenOffice Writer.

Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129
476rick
  • 2,764
  • 4
  • 29
  • 49

1 Answers1

1

Check the TextTable property of the cursor. For example:

If Not IsEmpty(oVC.TextTable) Then tableName = oVC.TextTable.getName()

See also Listing 8.3 of Andrew Pitonyak's macro document.

Jim K
  • 12,824
  • 2
  • 22
  • 51