count cells in a range

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am trying to write a function in excel. Part of the input is a range of
cells in a column. What do I need to write to allow me to count the number of
cells in that range?

Thanks in advance.
 
Hi fullers,
If the input range is selected and only in one column then:
Selection.rows.count
returns the number of cells in that range.
Is this what you are after?
Ken Johnson
 
fullers said:
I am trying to write a function in excel. Part of the input is a range of
cells in a column. What do I need to write to allow me to count the number of
cells in that range?

Thanks in advance.
If the range (e.g., Range1) is a collection of cells rather than a
collection of rows or columns, then

Range1.Count

Alan Beban
 

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

Back
Top