Home |
Search |
Today's Posts |
#1
|
|||
|
|||
Is there a way to SUM based on formatting of a number?
I have a column of $ formatted numbers. Some of them are bold and the others
are not. I would like to Sum the column based on whether the bold formatting is applied or not. Is there a way to do this? (doesn't appear to be) If there isn't, then let me explain what I am looking for ultimately. I want to have two totals for this column of $. One that includes everything and one that includes everything that isn't "marked". Bolding a cell is a really easy and visual way of marking a cell. Is there some other way I could mark a cell and is visible and I can conditionally sum the values? Thanks, Tim |
#2
|
|||
|
|||
You could sum based on formatting if you use VBA, Chip Pearson has some VBA
functions that will sum based on cell color here http://www.cpearson.com/excel/colors.htm If you search Google you should be able to find some VBA solutions to "sum bold fonts" -- Regards, Peo Sjoblom (No private emails please) "timz" wrote in message ... I have a column of $ formatted numbers. Some of them are bold and the others are not. I would like to Sum the column based on whether the bold formatting is applied or not. Is there a way to do this? (doesn't appear to be) If there isn't, then let me explain what I am looking for ultimately. I want to have two totals for this column of $. One that includes everything and one that includes everything that isn't "marked". Bolding a cell is a really easy and visual way of marking a cell. Is there some other way I could mark a cell and is visible and I can conditionally sum the values? Thanks, Tim |
#3
|
|||
|
|||
"timz" wrote: I have a column of $ formatted numbers. Some of them are bold and the others are not. I would like to Sum the column based on whether the bold formatting is applied or not. Is there a way to do this? (doesn't appear to be) If there isn't, then let me explain what I am looking for ultimately. I want to have two totals for this column of $. One that includes everything and one that includes everything that isn't "marked". Bolding a cell is a really easy and visual way of marking a cell. Is there some other way I could mark a cell and is visible and I can conditionally sum the values? Thanks, Tim A simple function could be Function BoldSum(rng) Dim c For Each c In rng If c.Font.Bold Then BoldSum = BoldSum + c.Value End If Next End Function Copy function into VB Module and use within the book. Peter Atherton |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Conditional Formatting based on Text within Text | Excel Discussion (Misc queries) | |||
conditional formatting based on column | Excel Discussion (Misc queries) | |||
Calculate percentage based on cells with conditional formatting | New Users to Excel | |||
Conditional formatting based on if statement. | Excel Worksheet Functions | |||
How to do a conditional formatting based on an adjacent cell | Excel Discussion (Misc queries) |