# Getting an average for cells containing formula

##### New Member
Hello,

I have cells C5:C36 that contain a series of IF formulas (=IF(B5="L4(+)","95%",IF(B5="L4","85%",IF(B5="L4(-)","80%",IF(B5="L3(+)","79%",IF(B5="L3","75%",IF(B5="L3(-)","70%",IF(B5="L2(+)","69%",IF(B5="L2","65%",IF(B5="L2(-)","60%",))))))))) that reference the adjacent cells B5:B36. When I enter the desired text in the B column cells it returns the desired value in the C column just fine.

My issue is I now want to be able to average the values in the C columns (which are all percentages). However, when I use the Average function for the percentage value in the C column, it returns a Div/0 error.

I'm assuming that the Average function is reading the cells in column C as blank and so it returns the Div/0 error.
I've resorted to retyping the percentage values in the C column into the adjacent D column and then averaging those percents. This of course is redundant and time consuming.

I'd like a solution that would just average the returned percentage value in the C column.

### Excel Facts

How can you automate Excel?
Press Alt+F11 from Windows Excel to open the Visual Basic for Applications (VBA) editor.

#### etaf

##### Well-known Member
are they actually % or TEXT
"95%" is not a % is text and so that maybe the issue

is the column formated as text or % ]if % then
change to the % value ie

=IF(B5="L4(+)",0.95,IF(B5="L4",0.85,IF(B5="L4(-)",0.8,IF(B5="L3(+)",0.79,......etc

##### New Member
Wow! Thank you so much. Such a simple solution and it works perfectly!

#### etaf

##### Well-known Member
you are welcome

Replies
4
Views
232
Replies
1
Views
189
Replies
5
Views
315
Replies
3
Views
460
Replies
3
Views
291

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,163,846
Messages
5,833,937
Members
430,247
Latest member
w9u5280o

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