ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Selecting every odd row (https://www.excelbanter.com/excel-discussion-misc-queries/30926-selecting-every-odd-row.html)

instauratio

Selecting every odd row
 
I have a spread sheet with 2000 rows. I want to select every odd row and move
it to aother sheet. Keeping the even rows on the first sheet. I want to
select them without having to go through and select each one separately (1000
selections).

I know this sounds bizarre, but if i can do this it will save me hours of
work.


Barb R.

That's easy! Try this equation and use AUTOFILTER to select the rows you
need to copy and copy them to the sheets as needed..

=MOD(ROW(),2)

Barb Reinhardt

"instauratio" wrote:

I have a spread sheet with 2000 rows. I want to select every odd row and move
it to aother sheet. Keeping the even rows on the first sheet. I want to
select them without having to go through and select each one separately (1000
selections).

I know this sounds bizarre, but if i can do this it will save me hours of
work.


Dave O

Here's one way to do it:
Step 1: make a backup copy of your data so you don't lose anything.
Step 2: At the left-most column, insert 2 new columns.
Step 3: In the new column A, starting at row 1, number each row using
your favorite method (data fill, etc).
Step 4: In the new column B, in row 1, enter 0. In the following row,
enter 1. In the row after that, enter this formula: =B1 (or whatever
row holds the zero value in this column). Copy this formula down to
the last column. You should see 0,1,0,1 etc alternating through the
entire list.
Step 5: Sort all rows on column B. All the zero entries will be
grouped; all the 1 entries will be grouped.
Step 6: Move the appropriate group to a new tab.

Column A will allow you to re-sort data into its original order if for
some reason it gets out of order.



All times are GMT +1. The time now is 02:13 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com