ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Multiple Values (https://www.excelbanter.com/excel-discussion-misc-queries/36167-multiple-values.html)

PW11111

Multiple Values
 

Hi

I a drop down box with the following values that the user can selet

1-4
5-8
9-12

In the next column I have a formula that converts the above into a number -
so it can be used in a formula.

=IF(H5= "1-4",4)

How do I add to the above formula a condition that says if "5-8" is entered
in H5 then the cell = 8 and if "9-12" is entered the cell = 12.

I know how to right individual bits - but not combine them together.

I hope this makes sense.

Cheers,

Phil


aristotle

Hi,

This displays the final segment using "-" as the delimiter. Hope this is
what you're looking for.

=VALUE(RIGHT(A1,LEN(A1)-FIND("-",A1,1)))

Regards,
A
--
We are what we repeatedly do. Excellence, therefore, is not an act, but a
habit.


"PW11111" wrote:


Hi

I a drop down box with the following values that the user can selet

1-4
5-8
9-12

In the next column I have a formula that converts the above into a number -
so it can be used in a formula.

=IF(H5= "1-4",4)

How do I add to the above formula a condition that says if "5-8" is entered
in H5 then the cell = 8 and if "9-12" is entered the cell = 12.

I know how to right individual bits - but not combine them together.

I hope this makes sense.

Cheers,

Phil



All times are GMT +1. The time now is 02:31 PM.

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