count number of rows in 2 worksheets
You have some answers in your first posting of this question. However, I'd
like to tell you that your question is not defined very well. You have to
tell us what you mean by "used rows". For example, if there are blank rows
inside your data, are they to be counted or not (in other words, are you
looking for the last cell with data or an actual count of data rows with
blank rows excluded)? What about formulas? If you have formula evaluating to
the empty string (""), is that considered "used" (it has something in it,
but that something is displaying the empty string, so you can't see
anything)?
--
Rick (MVP - Excel)
"Rachel" wrote in message
...
HI,
Anyone can help? I need a macro code to count number of used rows in two
seperate worksheets and compare. If the number do not match error message
shall appear "Sheet1 has (blank) number and Sheet2 has (blank) number".
(blank) being the number of used rows per sheet. Can this be done? thanks!
|