IF statement followed by VLOOKUP followed by another IF statement

Russmeister57

New Member
Joined
Jun 5, 2015
Messages
15
Office Version
  1. 2010
Platform
  1. Windows
Hi all,

I've had a look through the forums and cant find exactly what i need.

I'm looking for an IF statement, leading into a VLOOKUP, and then leading into another IF statement if this is possible.

So far i have the below formula. It works almost how i need it to but it doesn't return an exact value.

=IF(B12>="1",VLOOKUP(B12,Agency!$B$1:$D$200,3,IF(B12>="1",11.25,"")),"")

So if B12 is greater than 1 (this cell has a formula in it so i need to recognize a value, not the formula [this value is a name]), then look in 'Agency!B1:D200, for a corresponding name in column B and return value in column D, but if the VLOOKUP is false, then to carry out the next IF statement, if B12 is greater than 1, then to simply return the value "11.25"

I'm not quite sure this is possible in this format but any help would be appreciated.

Thank you
 

Excel Facts

What is the last column in Excel?
Excel columns run from A to Z, AA to AZ, AAA to XFD. The last column is XFD.
"1" is text and not a number - so you just need to use 1

Not sure i follow as B12 is a number >1
BUT then you say lookup B12 - NAME in column Agency!B:B

is it a number or a name ??

maybe include an IFERROR

=IFERROR ( VLOOKUP(B12,Agency!$B$1:$D$200,3,false ) , 11.25)

that will lookup the value in B12 and return the value in D - for n exact match
If it cannot find B12 in agency!B:B , then it will return 11.25

but as i say,. i'm not following the question

Therefore -

A SMALL sample spreadsheet, around 10-20 rows, would help a lot here, with all sensitive data removed, and expected results mocked up and manually entered, with a few notes of explanation.

This will possibly enable a quicker and more accurate solution for you.

MrExcel has a tool called “XL2BB” that lets you post samples of your data and will allow us to copy/paste your sample data into our Excel spreadsheets, saving a lot of time.

You can also test to see if it works ok, in the "Test Here" forum.

OR if you cannot get XL2BB to work, or have restrictions on your PC

then put the sample spreadsheet onto a share

I only tend to goto OneDrive, Dropbox or google docs , as I'm never certain of other random share sites and possible virus.
Please make sure you have a representative data sample and also that the data has been desensitised, remember this site is open to anyone with internet access to see - so any sensitive / personal data should be removed

Make sure you set any share or google to share to everyone
 
Upvote 0
Hi guys, sorry for the late reply.
Your right, i was just missing the IFERRROR.
=IF(B12>=1,IFERROR(VLOOKUP(B12,Agency!$B$1:$D$200,3,0),IF(B12>="1",11.25,"")),"")

Thank you
 
Upvote 0
you are welcome
glad it worked
just remember that
"1" is text and not seen as a number - in some other formulas (not all) it may not work if using this result as a number
 
Upvote 0

Forum statistics

Threads
1,225,738
Messages
6,186,725
Members
453,368
Latest member
positivemind

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