Replace a value with a name

telluride

New Member
Joined
Nov 9, 2005
Messages
4
Is there a way that I can assign a value to "apple" (has a value of 3) and "orange" (has a value of 2) such that I could reference the cells they are in my formula (not write apple or orange in the formula)

Example A1 + B1 = 5 (Not Apple + Orange = 5)
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
telluride said:
Is there a way that I can assign a value to "apple" (has a value of 3) and "orange" (has a value of 2) such that I could reference the cells they are in my formula (not write apple or orange in the formula)

Example A1 + B1 = 5 (Not Apple + Orange + 5)

How many of these do you have? You can use Sumproduct/Lookup

=SUMPRODUCT((LOOKUP(A1:B1,C1:D10)))

Where C1:D1 houses fruits sorted in ascending order and associated values in D1:D10

Edited for spelling!
 
Upvote 0
Not sure I follow what you are trying to do,

If you just want to reference cells, put the value 3 for an apple in A1 and the value 2 for an orange in A2, then A1 + A2 = 5

If you want to name some ranges; clcik on cell A1 containing the value 3 and then from the top menu use;
INSERT .. NAME .. DEFINE .. call it apple

then click on cell A2
INSERT .. NAME .. DEFINE .. call it orange

now in cell C1 enter =apple + orange
 
Upvote 0

Forum statistics

Threads
1,214,652
Messages
6,120,746
Members
448,989
Latest member
mariah3

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