Conditional Row Selection
Posted by Cory on June 25, 2001 8:42 AM
This one should be easy, but I still need some help: I have a sheet that was FTP'd in and it contains the headers that would've shown up if the document was printed in its original program. I'm trying to automate by use of a command button the deletion of these headers. They don't occur a set distance from one another, but they do contain the same text. Each header is five rows deep.
Example:
Company Name
Company Address
Wharehouse Number
Report Dates
Report Times
[Big block of data that needs to be kept]
Company Name
Company Address
etc., etc...
I tried using a macro with the find control (Cont + F) to search for the data, activate the cell where the data occurs, use the offset property to go to the beginning of the header, select that row and the five underneath, delete those rows, them start again looking for the next occurence of the header.
I've gotten it to find the first header, but I can't get it to do the rest without excel selecting a specific range of cells (the headers aren't equidistant from one another).
HELP!!!!!!