Solved

Excel - How to build a formula with part of the value coming from another cell

Posted on 2013-12-02
4
384 Views
Last Modified: 2013-12-02
I have a completely basic formula in cell H2, for example:  "=A2-B2"

Now I want to dynamically enter a letter in cell A1, e.g. "C" so that the result that I see in H2 is the difference between cell A2 and C2.

Or another way of asking the question:  How can I modify my formula in H2 so that when I enter "C" into cell A1, the formula in H2  changes to "=A2-C2"  ?

My bumbling attempt at trial-and-error for cell H2, in case it clarifies my question:
"=A2-(A1)2"   No joy

Thanks
0
Comment
Question by:Dwight Baer
  • 2
  • 2
4 Comments
 
LVL 43

Expert Comment

by:Saqib Husain, Syed
ID: 39690641
=a2-indirect(A1 & "2")
0
 

Author Comment

by:Dwight Baer
ID: 39690674
Wonderful.  One little thing more ...
How can I modify that so that I can  copy it?  When I copy it into H3, for example, I need to formula to read "=a3-indirect($A$1 & "3")

Thanks again.
0
 
LVL 43

Accepted Solution

by:
Saqib Husain, Syed earned 500 total points
ID: 39690682
"=a3-indirect($A$1 & row())
0
 

Author Comment

by:Dwight Baer
ID: 39690694
Fantastic!!  Thanks
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Sparklines have been introduced with Excel 2010 and are a useful tool for creating small in-cell charts, used for example in dashboards. Excel 2010 offers three different types of Sparklines: Line, Column and Win/Loss. What it does not offer is a…
INDEX and MATCH can be used to great effect to replace HLOOKUP and VLOOKUP as it does not have the limitation of needing the data to be sorted so that the reference value is in the first column or row. It also has the ability to perform a bi-directi…
The view will learn how to download and install SIMTOOLS and FORMLIST into Excel, how to use SIMTOOLS to generate a Monte Carlo simulation of 30 sales calls, and how to calculate the conditional probability based on the results of the Monte Carlo …
The viewer will learn how to use a discrete random variable to simulate the return on an investment over a period of years, create a Monte Carlo simulation using the discrete random variable, and create a graph to represent the possible returns over…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now