I want the user to be able to select cells, then have my function operate on those cells.
How do I do that? "ByRef" and "as Object" seem to do the right thing, but then Excel/{Libre,Open}Office reject the function call because the user's input is not an object.
Is there a way to find out what cells were selected for the function to be run on?
Even if I had to do something like find the address of the calling cell, then work backward to find the cell-names typed into that cell, that might work. I am open to any solution that lets my users write this function like a normal function, and has this function be able to modify the selected cells. Here is what I'm talking about:
Function SIMVOL( rF, ByRef mX, mY, cR, cS ) ' or Function SIMVOL(...mX as Object...)
mX.value() = 10
SIMVOL = mX.value() * mY
End Function