Formula to ignore field if cell contains a value

Panthera

New Member
Joined
Mar 4, 2016
Messages
11
Hi,

I've been stuck on this for a while and need your help to progress. I have around 7000 rows of duplicate values and I'm trying to filter out certain elements. I want to retain all duplicate values if one of the UserNames have a Value in colum A...

As long as the "UserName" column is filtered A-Z I can fill in the blank fields with the help of the following formula and it will highlight the rows I need to delete by giving a FALSE statement.

=IF(B2=B1,A1)

Using this formula in the empty cells in column A will mark A2, A3 with Value1, A4, A5, A6 with FALSE and A8 with Value2, so all good so far as I can then delete the FALSE rows... My problem is that I have 7000 rows and copying the formula into only the empty rows will take forever.

Is there a way to get the formula to ignore and retain the value in A1 and A7 if I were to apply the formula to all of column A? OR is there a better approah to mark UserName 2 and 3 for deletion?

Value1UserName 1
UserName 1
UserName 1
UserName 2
UserName 2
UserName 3
Value2
UserName 4
UserName 4
 

Excel Facts

Spell Check in Excel
Press F7 to start spell check in Excel. Be careful, by default, Excel does not check Capitalized Werds (whoops)
copying the formula into only the empty rows will take forever.
Try this with a copy of your data

Select the whole of column A by clicking its heading label.
Press F5 -> Special... -> Blanks -> OK
Enter your =IF(B2=B1,A1) formula in the formula bar and press Ctrl+Enter

Filter FALSE & delete
 
Upvote 0

Forum statistics

Threads
1,214,416
Messages
6,119,386
Members
448,891
Latest member
tpierce

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top