UDF: Celll Row Number

  • Thread starter Thread starter Arun
  • Start date Start date
A

Arun

I'm writing a UDF function that requires the row number of the cell it's in.
How do I write a simple UDF that returns the row in which the function is
called from?

For example, the function RowFind below will return the value the CURSOR is
in.

Function RowFind
RowFind = ActiveCell.Row
End Function

Is there a an alternative to ActiveCell that will give the cell the FUNCTION
is in?

Thanks!
 
Function RowFind()
RowFind = Application.Caller.Row
End Function
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

UDF's 5
UDF in module of personal.xls 3
Including Help in UDF 2
Formula vs. Constant 24
How to count cells colored red? 3
thiscell and udf 1
UDF question 9
Can UDF return a customized hyperlink? 3

Back
Top