Microsoft Office Forums


Reply
Thread Tools Display Modes

Re: vlookup question

 
 
Max
Guest
Posts: n/a
 
      12-17-2005, 11:11 PM
Assuming the price table is in Sheet1, in A1:G11

In Sheet2,

With quantities listed in A2 down, colors listed in B2 down

To retrieve the unit-prices, put in C2:
=IF(OR(ISNA(MATCH(A2,Sheet1!$A$1:$A$11,1)),ISNA(MA TCH(B2,Sheet1!$A$1:$G$1,0)
)),"",INDEX(Sheet1!$A$1:$G$11,MATCH(A2,Sheet1!$A$1 :$A$11,1),MATCH(B2,Sheet1!
$A$1:$G$1,0)))

Copy C2 down as far as required

Sample construct at:
http://cjoint.com/?msbku8PWTL
Retrieving UnitPrices From Reference Table_DaveJohnson_gen.xls

--
Rgds
Max
xl 97
---
Singapore, GMT+8
xdemechanik
http://savefile.com/projects/236895
--
"Dave Johnson" <(E-Mail Removed)> wrote in message
news:TS0pf.618$(E-Mail Removed)...
> My wife owns a t-shirt company and I'm trying to help her write a
> spreadsheet that will calculate price per shirt printed using a vlookup
> formula.
>
> The table has 10 rows of quantities in the left column and 6 colums of
> colors 1-6 across the top row. As long as I only use one vlookup (for a

one
> sided print job) it works perfectly. Where I'm getting stuck is when I try
> to add a second vlookup for the number of colors to be printed on the back
> of each shirt.
>
> As long as I have a quantity of 1 to 6 it works fine. It's when the value

is
> 0 or blank that something is going very wrong. The result is very high,

$106
> per shirt when it should be $3.30.
>
> How do I get my formula to ignore the second vlookup if the value is 0?
>
> =((VLOOKUP(B12,D6:J16,B9+1)+(B16/B12)+B8)+VLOOKUP(B12,D6:J16,B10+1))/B6
>
> 1 2 3 4 5 6
> 1 20.00 40.00 60.00 100.00 125.00 150.00
> 12 5.00 6.00 7.00 8.00 9.00 10.00
> 24 2.00 2.50 3.00 3.50 4.00 4.50
> 48 0.95 1.20 1.50 1.80 2.10 2.40
> 72 0.85 1.15 1.35 1.55 1.75 1.90
> 144 0.75 1.05 1.25 1.40 1.55 1.75
> 288 0.65 1.00 1.20 1.35 1.50 1.60
> 576 0.50 0.90 1.10 1.25 1.40 1.50
> 1200 0.45 0.55 0.65 0.75 0.85 0.95
> 3000 0.40 0.45 0.55 0.65 0.75 0.85
>
>
> Thanks for any help with this.
>
> Dave
>
>
>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: vlookup question Bob Phillips Excel Newsgroup 0 12-17-2005 10:18 PM
vlookup question Urgent!! J T Excel Newsgroup 3 10-14-2004 04:38 PM
vlookup newbie question a911er@hotmail.com Excel Newsgroup 1 01-17-2004 09:04 PM
Vlookup question Buckwheat Excel Newsgroup 2 12-18-2003 05:03 AM
vlookup question. IowaBuckMaster Excel Newsgroup 5 11-26-2003 12:17 AM



All times are GMT. The time now is 02:35 PM.
Microsoft Office Forums is not affiliated with Microsoft Corporation.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92