how show sum & avg same time in status bar?
Sandy/Ian
You can put this code once in the Thisworkbook module as such.........
Private Sub Workbook_SheetSelectionChange(ByVal Sh As _
Object, ByVal Target As Range)
Dim x As String
Application.DisplayStatusBar = True
On Error Resume Next
x = CStr("Sum=" & Application.WorksheetFunction.Sum(Selection) & " " & _
"Average=" & Application.WorksheetFunction.Average(Selection))
Application.StatusBar = x
End Sub
Will work on the active worksheet.
Gord Dibben MS Excel MVP
On 6 Oct 2006 11:02:20 -0700, "Sandy" wrote:
You'll need to put this in each sheet level to have it work through the
whole workbook.
|