Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 11-30-2009, 03:40 AM
thelauncher thelauncher is offline Using Vlookup & IF together Windows Vista Using Vlookup & IF together Office 2003
Novice
Using Vlookup & IF together
 
Join Date: Nov 2009
Posts: 1
thelauncher is on a distinguished road
Question Using Vlookup & IF together

Hi all,



I'm having trouble trying to figure out a formula using IF and Vlookup. Basically what I need is to lookup a value from sheet1 that should be somewhere in sheet2. Once vlookup has located this value it then needs to go a certain amount of columns accross eg 10 in sheet2 to find another value (as a normal vlookup does). Now I cant figure it out: IF the value in sheet2 in this cell matches a value in sheet1 then I need the formula to return a 1, if it does not match then I need it to return a 0. I cant quite figure out how the formula would go, with nested functions etc

If anyone could assist that would be great as its driving me mad

launcher
Reply With Quote
  #2  
Old 01-14-2010, 01:43 PM
BjornS BjornS is offline Using Vlookup & IF together Windows Vista Using Vlookup & IF together Office 2003
Competent Performer
 
Join Date: Jan 2010
Location: Sweden
Posts: 116
BjornS is on a distinguished road
Default

Hi,
I think this formula solves it for you (translated, I hope it is correct).

=IF(ISERROR(VLOOKUP(A6;data;1;FALSE));0;1)

See attachment for an example.

/Bjorn
Attached Files
File Type: xls example1.xls (13.5 KB, 47 views)
Reply With Quote
  #3  
Old 01-17-2010, 08:53 PM
ConneXionLost's Avatar
ConneXionLost ConneXionLost is offline Using Vlookup & IF together Windows XP Using Vlookup & IF together Office 2003
Simulacrum
 
Join Date: Jan 2010
Location: Victoria, Canada
Posts: 86
ConneXionLost is on a distinguished road
Default

Hi launcher,

Instead of guessing at what you mean by "a certain amount" and providing an inaccurate solution, would you please post a sample spreadsheet?

Cheers,
Reply With Quote
  #4  
Old 08-20-2013, 07:43 AM
michael excel master michael excel master is offline Using Vlookup & IF together Windows 7 32bit Using Vlookup & IF together Office 2010 32bit
Novice
 
Join Date: Aug 2013
Posts: 1
michael excel master is on a distinguished road
Default

sure bro post a sample and we help u out there and then
Reply With Quote
  #5  
Old 08-25-2013, 10:19 PM
excelledsoftware excelledsoftware is offline Using Vlookup & IF together Windows 7 64bit Using Vlookup & IF together Office 2003
IT Specialist
 
Join Date: Jan 2012
Location: Utah
Posts: 455
excelledsoftware will become famous soon enough
Default

Quote:
Originally Posted by thelauncher View Post
Hi all,

I'm having trouble trying to figure out a formula using IF and Vlookup. Basically what I need is to lookup a value from sheet1 that should be somewhere in sheet2. Once vlookup has located this value it then needs to go a certain amount of columns accross eg 10 in sheet2 to find another value (as a normal vlookup does). Now I cant figure it out: IF the value in sheet2 in this cell matches a value in sheet1 then I need the formula to return a 1, if it does not match then I need it to return a 0. I cant quite figure out how the formula would go, with nested functions etc

If anyone could assist that would be great as its driving me mad

launcher
have you tried a countif formula. It will look if something exists on sheet 2 from what is on sheet 1. =countif('sheet2'!A:A,'sheet1'!a1)

This will count how many times that record exists. as far as nesting formulas it is easy to get comfortable with this by watching the tooltips.

For example when writing an if statement you start with =if(
now the tool tips will tell you that you are writing the condition. then you press a comma and it asks for what you want if the condition is true. You can put another formula in here if you want. try a sum write =if(a1=9,sum(6+3),sum(6-3))

Notice the last parentheses to close off the original if formula. It is very good to get comfortable with nesting functions. give it a shot and let us know what you come up with.
Reply With Quote
  #6  
Old 08-25-2013, 11:32 PM
Pecoflyer's Avatar
Pecoflyer Pecoflyer is offline Using Vlookup & IF together Windows 7 64bit Using Vlookup & IF together Office 2010 64bit
Expert
 
Join Date: Nov 2011
Location: Brussels Belgium
Posts: 2,771
Pecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant future
Default

4 year old thread......
__________________
Did you know you can thank someone who helped you? Click on the tiny scale in the right upper hand corner of your helper's post
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
vlookup question Tony G Excel 9 03-28-2009 11:16 PM
Using Vlookup & IF together Vlookup and If statement problem bunnygum Excel 1 03-24-2009 05:10 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 11:23 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft