ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   IF formula (https://www.excelbanter.com/excel-discussion-misc-queries/57612-if-formula.html)

John Q

IF formula
 
Thanks to Dave for responding last week, but not there yet! I'll restate the
question differently. I have a dollar value in column G, if I enter one of
the following numbers, 81,82,83,84 in column D, I want $25 to add to my
dollar value in column G.
--
Thank you. John Q.

Eddie O

IF formula
 
Is the dollar value already in column G the product of a formula, or is it
static. If it's the product of a formula, what does the formula reference?
If it's static, the only way to do what you're saying is with a macro (not
my expertise, personally).

"John Q" wrote:

Thanks to Dave for responding last week, but not there yet! I'll restate the
question differently. I have a dollar value in column G, if I enter one of
the following numbers, 81,82,83,84 in column D, I want $25 to add to my
dollar value in column G.
--
Thank you. John Q.


John Q

IF formula
 
Thanks Eddie. The value is static. If I change what I am doing just slightly,
in column E is a formula, and it multiplies a qty in col B times the static
price in col G. Then the $25 could be added to Col E, but would need to be
multiplied times the qty in column B.
--
Thank you. John Q.


"Eddie O" wrote:

Is the dollar value already in column G the product of a formula, or is it
static. If it's the product of a formula, what does the formula reference?
If it's static, the only way to do what you're saying is with a macro (not
my expertise, personally).

"John Q" wrote:

Thanks to Dave for responding last week, but not there yet! I'll restate the
question differently. I have a dollar value in column G, if I enter one of
the following numbers, 81,82,83,84 in column D, I want $25 to add to my
dollar value in column G.
--
Thank you. John Q.


[email protected]

IF formula
 
"John Q" wrote:
I have a dollar value in column G, if I enter one of
the following numbers, 81,82,83,84 in column D, I
want $25 to add to my dollar value in column G.


Not exactly sure what you want. Does the following
meet your need? It is literally what you asked for:

=IF(AND(81<=D1,D1<=84),G1+25,G1)

That assumes that you have corresponding cells in
D and G. If the value 81-84 appears in only one cell,
replace "D1" with "$D$1"; that is, the absolute cell
location or name.

But you will not be able to put that into G1. You
will have to put that into H1, for example.

Alternatively, replace "G1" with "the dollar value"
that you intended, and put the formula into G1.
But that means you must edit the cell in two places,
instead of simply entering "the dollar value". If
editing is acceptable, the following formula will
reduce the amount of editing (where "100" represents
"the dollar value"):

=100+IF(AND(81<=D1,D1<=84),25,0)



All times are GMT +1. The time now is 10:30 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com