开发者

Assign value to list

First and foremost. I'm totally new to "programming" in Excel.

I'm trying to make a price calculator, that calculates the price when I use my printer. The sheet contains list, so I don't need to type in numbers but can choose between some options.

I would like options within the list to have a value.

My sheet contains theese information.

Description, Amount, Single/duplex, Format, Printing price, Paper price, Total price.

Description: Could be "Printing an invitation for my brother"

Amount: Amount printet

Single/Duplex: A list containing "Single" and "Duplex"

Format: A list containing "A4", "SRA3" and "SRA3 HiGloss"

Printing price: The total price

This is how it's calculated:

'Format' + ('Amount' x 'Single/duplex') = 'Printing price'

I would like to 开发者_如何学编程assign theese values to the list options:

Single/Duplex

Per page (singlex): 0,6

Per page (duplex): 1,2

Format:

A4. paper: 0,2

SRA3 High Gloss: 1,25

SRA3: 1

Example

Description Amount      Single/Duplex       Format          Printing price
Invitations 30          Duplex              SRA3 HiGloss    61,25

The calculation for this example looks like this:

'Format' + ('Amount' x 'Single/duplex') = 'Printing price'

1,25+(30*2)

Does anyone know about this???


I would make a price lookup sheet and have the prices laid out in table form i.e.

A          B

Single  0.6

Duplex  1.3

A4      0.2

And so on…

You can then use the vlookup function to turn the options given into their value counterpart

=VLOOKUP(B3,Price_lookup!A1:B20,2,FALSE)

You can then use this as the basis for building your formula

EDIT:

Ok here is a very rough example in excel but it works. You can unhide the columns to show how it works

http://www.easy-share.com/1910066813/Stack_example.xls

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜