Thread: One more macro
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Grace[_4_] Grace[_4_] is offline
external usenet poster
 
Posts: 106
Default One more macro

I have a worksheet. Starting in row 21, I want it to see if the entry in
column A is a number. If it is, I want it to go down one row and try again,
i.e., test cell A22 to see if it is a number. If cell A21 is not a number,
I want it to delete that entire row and then look at the entry in the new
cell A21. If I have to put a maximum on it, I'd say there will not be more
than 600 rows to test.

When it is done with this, I would like it to highlight the block from cell
A21 to the last row in column E. I would then like it to sort that block of
data by the column B entry, in ascending order. I would then like to copy
all data from cell A1 (the top left corner) down to the bottom right corner
of that same block and have it paste it into another file of my choice,
starting at its cell A1 of one or two worksheets. It would be pasted into
one of two worksheets, either BOPCompHldgs or EOPCompHldgs, so I would need
it to ask me which of the two sheets I want to paste into.

There's a few other things after that, but I think I can handle that myself
from the other stuff I've learned. Kindly help.

Grace