Liu Chang
Liu Chang

Reputation:

How to use Openoffice calc add-in that returns a range?

I am writing an OpenOffice calc add-in that returns a range of strings:

public String[][] myFunc(int v0, com.sun.star.table.XCellRange v1)

When I try to use the function in OpenOffice and set a cell's value to

=myFunc(0;A1:B1)

Only the first value returned by myFunc is shown as the value of the cell. How can I make the value appear in a range of cells, to the effect of

C1:D1=myFunc(0;A1:B1)

?

Thank you.

Upvotes: 2

Views: 836

Answers (1)

Liu Chang
Liu Chang

Reputation:

I found a link that explains this:

http://www.openofficetips.com/blog/archives/2004/10/array_formulas.html

In short, select cell C1, enter the formula =myFunc(0;A1:B1), and press Ctrl-Shift-Enter instead of Enter. This functionality doesn't seem to be accessible from the menu though. Not very intuitive I have to admit!

:)

Upvotes: 2

Related Questions