1

Is it possible to use an IF statement to output a named cell value from another sheet (in the same doc)?

I have a large sheet with various product prices for my store and so one of the fields is the cost of shipping. At the moment I have a sheet with various values for shipping and each one has the cell with a name - eg. a cell on that sheet (call it "sheet2") has a value of £6.50 and it's called "DPDLocalShipping" and another cell has a value of £10 and is called "DPDLocalShippingBox"

On "sheet1" where all my products are, if I use "=DPDLocal" it outputs the value no problem but I'd like to use a statement in the shipping field that takes a product value and if it's above a certain value, it would either output a shipping cost from DPDLocal or DPDLocalLarge but if I do something like this

=if( J7 > 225, "DPDLocalShippingBox", "DPDLocalShipping")

The value in J7 is the product price.

When I try this formula, it just renders out DPDLocalShipping in the shipping field so obviously something is wrong but I'm not entirely sure what or how to get the £ value to show in that field.

Thanks

1

1 Answer 1

1

To refer to named ranges, remove the double quotes in the formula, like this:

=if( J7 > 225, DPDLocalShippingBox, DPDLocalShipping )

1
  • that's done the job, thank you Commented Jul 27, 2022 at 15:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.