How to retrieve every n-th row from an excel sheet.
There are times when you have an excel file with a lot of rows and you want to fetch every n-th row from it.
Here is a simple solution.
Here is a simple solution.
- Create a new sheet in the same excel file where you would like to perform the operation.
- In the first row, paste this formula. =OFFSET(mainSheetName!A$2,(ROW()-1)*n,0)
In the above formula, mainSheetName should be replaced with the name of your main sheet.
A$2 denotes the data will be copied from A2 of the main sheet. Adjust this accordingly.
n is the variable which defines the recurring position of the values you would like to fetch.
If you want to fetch every 10th row, n=10. - Once you have successfully copied first row from main sheet to the new sheet, you can
simply copy the formula to right and bottom by dragging.
Comments
Post a Comment