CountA Problems
I plan to copy a few cells from a workbook "Store" to another one called
"Sales". I am putting this data into the worksheet in rows once a day. I am
using a command button on Sheet("Store") to do this with the following code:
Sub cmdUpdateSales()
Sheets("Sales").Activate
Sheets("Sales).Select 'this may be overkill
NextRow = Workbookfunction.CountA.Range("A1:A100") +1 'I want to count
the rows on "Sales"
MsgBox NextRow
More code here
End Sub
The results of the message box show that 0 rows have been counted, because
the NextRow functions seems to counting on Sheet("Store") instead of
Sheet("Sales"). Sheet("Sales") does have a header row which should give a
row count of at least "1". What am I doing wrong? Can you help?
Thanks for the help
TucsonBob
|