Sep 29 2021 11:54 PM
Sep 30 2021 01:18 AM
No, you'd need VBA for that. Here is a user-defined function that you can copy into a module in the Visual Basic Editor:
Function SumBold(rng As Range) As Double Dim cel As Range Application.Volatile For Each cel In rng If cel.Font.Bold Then SumBold = Application.Sum(SumBold, cel.Value) End If Next cel End Function
You can then use it in a formula such as
You'll have to save the workbook as a macro-enabled workbook and allow macros when you open it.
Warning: the formula result will not be updated automatically when you toggle the Bold property of a cell. It will be updated the next time Excel recalculates any formula. You can press F9 to update it immediately.
Sep 30 2021 02:21 AM
Here is another example without VBA
Go to: Formulas -> "Define Name"
Set a custom name:
Insert -> Name -> Define -> Name in the table: 'Bold' ->
(In the inserted example file you will find the correct settings for the table under the name manager.)
Now you can use the following column in any auxiliary column (here column B)
And get a 1 if the cell in the same row in column A is bold
Now you can use SUMMIF () to calculate the sum:
I would be happy to know if I could help.
I know I don't know anything (Socrates)
* Kindly Mark and Vote this reply if it helps please, as it will be beneficial to more Community members reading here.