View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Chip Pearson Chip Pearson is offline
external usenet poster
 
Posts: 7,247
Default application.caller

That results in a circular reference.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com
(email address is on the web site)

"Tom Ogilvy" wrote in message
...
set rng = Application.Caller

v = rng.Value

will give you the value of the cell containing the formula (which is
considered the calling cell).

--
Regards,
Tom Ogilvy


"Alexander" wrote in message
...
Thanks.

Is there a reliable way to get a value of calling cell? So the UDF can
return that value under some circumstances.

Cheers,
Alex.

"Tom Ogilvy" wrote:

? cvErr(xlErrRef)
Error 2023

this is the same as the #Ref error

I doubt it is caused by application caller, but more likely by the
argument
you are furnishing to the function.

--
Regards,
Tom Ogilvy


"Alexander" wrote:

Hi,

Application.Caller in my UDF function is always Error 2023 (called due
to
the cell change). Why?

Cheers,
Alex.