View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Gary''s Student Gary''s Student is offline
external usenet poster
 
Posts: 11,058
Default Detecting "CallingCell" In Function

Function who_called_me()
who_called_me = ""
MsgBox (Application.Caller.Address)
End Function

--
Gary's Student


"dec_obrien" wrote:


Hi,
I have a custom function that calculates the Date given various
conditions. What I want to do is conditionally format the cell from
where the function is called based on the day of the week calculated.
It's like "ActiveCell" for the calling cell of the function but
obviously ActiveCell will not be correct. I know I could pass the Cell
Row/ Column in as arguments to teh function but this seems a bit messy
if there an easier way of detecting this.

Any ideas?


--
dec_obrien
------------------------------------------------------------------------
dec_obrien's Profile: http://www.excelforum.com/member.php...o&userid=37705
View this thread: http://www.excelforum.com/showthread...hreadid=572994