I wanted to start off with a fairly simple excel macro first. Although simple, this macro is very helpful when you want to copy the sum of several cells in an excel spreadsheet. The cells can be scattered throughout the spreadsheet or all in the same row/column.
Note: This will just paste the value of the sum, not a sum( ) formula.
Excel Macro Code:
Sub CopySelectedSumValue() Dim MyDataObj As New DataObject MyDataObj.SetText Application.Sum(Selection) MyDataObj.PutInClipboard End Sub
View the full listing of macros.