# SUM with characters within the value

#### Polanskiman

##### Board Regular
Hello,

I have this set of data (See below).

For column A:
Sum seem to be working as long as both G15 AND G16 are not empty. Else it throws a #VALUE!. Obviously I can't have this happen since cells in the G13:G16 range can in some instance be empty.

For column B:
If either H15 or H16 (or both) values are absent then it throws a #VALUE! also. Same here. I can't have this happen.

I need that degree character to stay where it is else the calculation would be a breeze.

Can enyone help me fixing those formulas. I have been banging my head for quite some time now trying to make this work.

Thank you.

Book2
EFGHI
6
7
8multipler
92
10
11
12Column AColumn B
131 °
142 °
153 °1 °
164 °2 °
17Sub total white3 °2 °
18Total white + yellow13 °5 °
19
20
Sheet1
Cell Formulas
RangeFormula
G13,H15G13=1&" °"
G14,H16G14=2&" °"
G15G15=3&" °"
G16G16=4&" °"
G17G17=IF(SUM(IF(ISBLANK(\$G\$13:\$G\$14),"",IFERROR(VALUE(LEFT(\$G\$13:\$G\$14,SEARCH(" °",\$G\$13:\$G\$14)-1)),\$G\$13:\$G\$14)))=0,"",SUM(IF(ISBLANK(\$G\$13:\$G\$14),"",IFERROR(VALUE(LEFT(\$G\$13:\$G\$14,SEARCH(" °",\$G\$13:\$G\$14)-1)),\$G\$13:\$G\$14)))&" °")
H17H17=IF(SUM(IF(ISBLANK(\$H\$16),"",IFERROR(VALUE(LEFT(\$H\$16,SEARCH(" °",\$H\$16)-1)),\$H\$16)))=0,"",SUM(IF(ISBLANK(\$H\$16),"",IFERROR(VALUE(LEFT(\$H\$16,SEARCH(" °",\$H\$16)-1)),\$H\$16)))&" °")
G18G18=IF(AND(G15="",G16="",G17=""),"",IF(G17="",SUM(VALUE(LEFT(\$G\$15,SEARCH(" °",\$G\$15)-1)),VALUE(LEFT(\$G\$16,SEARCH(" °",\$G\$16)-1))),SUM(SUM(VALUE(LEFT(\$G\$15,SEARCH(" °",\$G\$15)-1)),VALUE(LEFT(\$G\$16,SEARCH(" °",\$G\$16)-1))),(VALUE(LEFT(\$G\$17,SEARCH(" °",\$G\$17)-1))*\$F\$9)))&" °")
H18H18=IF(AND(H15="",H17=""),"",IF(H17="",VALUE(LEFT(H15,SEARCH(" °",H15)-1)),SUM(VALUE(LEFT(H15,SEARCH(" °",H15)-1)),VALUE(LEFT(H17,SEARCH(" °",H17)-1))*F9))&" °")

Last edited:

### Excel Facts

How to change case of text in Excel?
Use =UPPER() for upper case, =LOWER() for lower case, and =PROPER() for proper case. PROPER won't capitalize second c in Mccartney

#### Polanskiman

##### Board Regular
Forgot to mention. Compatibility needs to be as wide as possible so any function that is specific to 2016 or newer should be avoided.

#### Fluff

##### MrExcel MVP, Moderator
Simplest, easiest & best way, is to remove the degree sign from the cell & use a custom cell format to show it instead.

#### Polanskiman

##### Board Regular
?

Any downside of using the formatting solution rather than hard coding the degree?

#### Fluff

##### MrExcel MVP, Moderator

Not that I can think of.

#### Polanskiman

##### Board Regular
Can't believe I didn't think of that before, really. Spent nearly all day trying to figure out that dam formula.

#### Fluff

##### MrExcel MVP, Moderator

Easily done, unfortunately

#### Polanskiman

##### Board Regular
Thank you Fluff. You saved me a great deal of time and pain from now on. ?

#### Fluff

##### MrExcel MVP, Moderator
You're welcome & thanks for the feedback.

Excel contains over 450 functions, with more added every year. That’s a huge number, so where should you start? Right here with this bundle.

1,167,650
Messages
5,854,948
Members
431,689
Latest member
jacker01

### 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.

### Which adblocker are you using?

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

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