RTsal
asked on
In Excel find the cells above a cell containing data
I have a column which contains some numbers but not in every cell. I want to identify the 2 cells directly above the cells containing data.
What do you mean identify? The two cells above every cell or one cell?
Can you post a sample of your sheet and how you want it to look? Do you want to calculate with the '2 cells above' values?
ASKER
I want to put something in the cells so I can sort/filter the column to show only the rows that have data in that column and the 2 cells directly above the cells with data
So why not do as gerwinjansen has suggested?
>> so I can sort/filter the column to show only the rows that have data in that column
When you filter on the column for rows that have values you will automatically get the '2 cells above' because you say that they also contain data. Could you please explain in more detail or post a sample. I'm afraid we can't help you otherwise. Thx.
When you filter on the column for rows that have values you will automatically get the '2 cells above' because you say that they also contain data. Could you please explain in more detail or post a sample. I'm afraid we can't help you otherwise. Thx.
ASKER
Here is a sample file. I want to add a word to the 2 cells immediately above any cell in the "Missing" column (Col. D) that has a number so that I can search sort and filter on that column and find the rows with the number in it and the 2 cells above them.
missing-sample.xls
missing-sample.xls
In your sample, add this formula to D2:
=IF(SUM(D3:D4)=0,"","Show" ) Replace word "Show" with required text.
Add an autofilter to the data and then Apply a "Show Blanks" filter to column D. D2 should still be visible.
Select D2 and all cells below. press Ctrl + D to fill down; those cells with values will not be overwritten because they are hidden.
You can now re-apply the filter to show Non Blanks.
Thanks
Rob H
=IF(SUM(D3:D4)=0,"","Show"
Add an autofilter to the data and then Apply a "Show Blanks" filter to column D. D2 should still be visible.
Select D2 and all cells below. press Ctrl + D to fill down; those cells with values will not be overwritten because they are hidden.
You can now re-apply the filter to show Non Blanks.
Thanks
Rob H
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.