Numbers and signs conversion to number

dbcooper88

New Member
Joined
Dec 3, 2016
Messages
36
How would I convert a number and sign to a number? For example how to convert 20- to 19.75 and 20+ to 20.25. TIA
 

Excel Facts

Excel motto
Not everything I do at work revolves around Excel. Only the fun parts.

Excel 2010
AB
120-19.75
220+20.25
Sheet8
Cell Formulas
RangeFormula
B1=LEFT(A1,LEN(A1)-1)+IF(RIGHT(A1,1)="-",-0.25,IF(RIGHT(A1,1)="+",0.25,0))


To keep it in the same cell you need VBA
 
Upvote 0
Thanks. Can you give me the formula for adding two more conditions making it a total of four conditions? For example 20" converts to 20.5 and a number with no signs = said number.
 
Upvote 0
Thanks. Can you give me the formula for adding two more conditions making it a total of four conditions? For example 20" converts to 20.5 and a number with no signs = said number.

Give this formula a try...

=IFERROR(LEFT(A1,LEN(A1)-1)+CHOOSE(FIND(RIGHT(A1),"-+"""),-0.25,0.25,0.5),0+A1)
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

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