EXCEL 2010

I would like to create a if than else function in excel.  I I have a large file of 7000 records I would like to set.
Example
if column a1 = "not mapped",
set column b1 = blank
and
set column c1 = blank
else
leave values to current status.

attaching a spreadsheet.
Excell_ifThenelseook1.xlsx
centralmikeAsked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
Rob HensonConnect With a Mentor Finance AnalystCommented:
With Saqib's suggestion of a formula.

Column D:

=IF($A1="Not mapped","",B1)   copy across to column E and down as far as required.

As suggested then hide columns B & C or copy and paste values from D & E overwriting B & C.  When copying a cell containing a formula resulting in "", the result of the value paste will not be an empty cell but will be '.

If you want the cells to be truly blank, an autofilter will recognise these as blank so you can filter to show only blank and delete them. When a filter is in place you can select the whole range of cells as one block but only visible cells will be affected by any actions taken. If you're going to do an autofilter to correct this, you might as well just do an autofilter in the first place as suggested by Saqib in his second comment.
0
 
Saqib Husain, SyedEngineerCommented:
I can think of two ways to do this.

1. No VBA. Use columns D and E for the result and hide columns B and C
2. With VBA

Which way do you want to go?
0
 
Saqib Husain, SyedConnect With a Mentor EngineerCommented:
Just thought of a third way.

Use Autofilter and filter the list for NOT MAPPED

Select the data in front of all the displayed rows and clear it

Unfilter the data
0
 
centralmikeAuthor Commented:
The following function worked great.
0
 
Rob HensonFinance AnalystCommented:
Maybe should share 50/50 with Saqib. Comment from OP does not state which answer was used.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.