View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
(PeteCresswell) (PeteCresswell) is offline
external usenet poster
 
Posts: 139
Default Invoke AutoSum From VBA?

Per Dave Peterson:
Sub DoAutoSum()
Dim x As CommandBarControl
Set x = CommandBars.FindControl(ID:=226)
If Val(Application.Version) 9 Then _
Set x = x.Controls(1)
x.Execute 'AutoSum
If Selection.Cells.Count = 1 Then
x.Execute 'Again to exit edit mode
End If
End Sub


That's the one I went with. Works like a champ!

Thanks Dave.

Thanks Bernie.

Thanks Peter.
--
PeteCresswell