The following, paste into the Sheet Module, will play the TADA sound when any change is made to the sheet :
Code:
Option Explicit
Private Declare Function PlaySoundA& Lib "winmm.dll" (ByVal lpszName$, ByVal hModule&, ByVal dwFlags&)
Private Sub Worksheet_Change(ByVal Target As Range)
'If Not Intersect([L3:L24], Target) Is Nothing Then '<--- For specific cell/s uncomment and specify the cell/s range
PlaySoundA "C:\windows\media\tada.wav", 0&, &H20001
'End If
End Sub
This is a basic email macro :
Code:
Option Explicit
Sub EmailSnd()
With CreateObject("outlook.application").CreateItem(0)
.to = "email address of recipient"
.Subject = "test"
.CC = "cc"
.BCC = "bcc"
.Body = "Hello ya all"
.Send
End With
End Sub
Bookmarks