Perhaps this can be fixed. Here's a script that looks like it should work, but it doesn't: ======================== function cell(sht,x,y) cell = ThisComponent.Sheets.getByName(sht).getCellByPosition(x,y) end function function simple(arg) '' Just returns the arg simple = arg end function function call_it(fn) call_it = fn("Hello!") end function sub main cell("Sheet1",0,0).String = call_it(simple) end sub ========================= When the "main" macro is run, the script fails while evaluating SIMPLE, complaining that "arg is not optional".
(In reply to comment #0) > When the "main" macro is run, the script fails while evaluating SIMPLE, > complaining that "arg is not optional". as it should do, simple is called with no arguments call_it(simple) = call_it(simple()) ^^ I see what you intend ( and it confused me into thinking this was a real bug first ) but the macro code is behaving perfectly as it should. I think you thought that perhaps simple was passed as some sort of functor to be called by call_it sorry, this just cannot work.