View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
joeu2004[_2_] joeu2004[_2_] is offline
external usenet poster
 
Posts: 829
Default writing a value to a particular cell from function

"Spint" wrote:
is there any way i can return a value from the function
and also inside the function some calculated value to be
set to particular cell.


No, not in a VBA function per se. You could do that in a VBA sub(routine),
but not one that is invoked by an Excel calculation (through a VBA function)
directly or indirectly.

Generally, Excel does not permit a VBA function to change the state of Excel
worksheets directly or indirectly. There are some exceptions, corner-cases
really. I don't remember them off-hand.