+ Reply to Thread
Results 1 to 4 of 4

VLookup

  1. #1
    Registered User
    Join Date
    07-07-2009
    Location
    Michigan
    MS-Off Ver
    Excel 2003
    Posts
    2

    Smile VLookup

    I am trying to create a multiple v look up formula to calculate the mileage from two destinations. I have a table with a From column, To Column, and miles column with data.

    I would like to automatically calculate the mileage determined upon what the user picks as the two destinations from a drop down list. Any suggestions?

    I thought it would work like this =VLOOKUP(B5:C5,G3:I14,2) But I'm not sure if I can have a range as the lookup value.

    I have attached my sheet I am working from.

    Lsiehda
    Attached Files Attached Files
    Last edited by lsiehda; 07-09-2009 at 11:26 AM.

  2. #2
    Forum Expert
    Join Date
    04-14-2009
    Location
    Taiwan
    MS-Off Ver
    Excel 2016,2019,O365
    Posts
    2,003

    re: VLookup

    Try this,

    =SUMPRODUCT(--(G4:G14=B5),--(H4:H14=C5),I4:I14)

    Hope this helps,
    windknife

  3. #3
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: VLookup

    You cities in a more standardized mileage chart. This allows you to do the work from any point to any point instead of needing to create special tables for each group.
    Attached Files Attached Files
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  4. #4
    Registered User
    Join Date
    07-07-2009
    Location
    Michigan
    MS-Off Ver
    Excel 2003
    Posts
    2

    Re: VLookup

    Thanks windknife, it worked!!!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1