If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Sumif cell has a boarder
Hi,
I have a spreadsheet with a column that has cells with totals and cells with just numerical data. Each cell that I want to total has a boarder around it. Is there anyway that I can Sum If a cell has a boarder? (Using the Subtotal function will not work in this case.) Thanks for your help! N |
#2
|
|||
|
|||
Sumif cell has a boarder
If indeed the data is either just plain numbers or sum formulas, one way
would be to select the column, press F5, click special, select formulas, copy, then paste somewhere else, this way you can paste them onto a new sheet, then just sum the whole column, then subtract the formulas that you copied somewhere else, i.e. =SUM(D195)-SUM(Sheet2!A1:A10) where D195 is the total of the range and sheet2 A1:A10 holds the totals. -- Regards, Peo Sjoblom wrote in message ... Hi, I have a spreadsheet with a column that has cells with totals and cells with just numerical data. Each cell that I want to total has a boarder around it. Is there anyway that I can Sum If a cell has a boarder? (Using the Subtotal function will not work in this case.) Thanks for your help! N |
#3
|
|||
|
|||
Sumif cell has a boarder
You may have to modify to suit your borders but try this
Sub sumborders() For Each c In [d9:d12] If c.Borders(xlEdgeLeft).LineStyle 0 _ Then mysum = mysum + c.Value Next MsgBox mysum End Sub wrote in message ... Hi, I have a spreadsheet with a column that has cells with totals and cells with just numerical data. Each cell that I want to total has a boarder around it. Is there anyway that I can Sum If a cell has a boarder? (Using the Subtotal function will not work in this case.) Thanks for your help! N |
Thread Tools | |
Display Modes | |
|
|