D
Desert Piranha
Hi All,
In Cell C9 is the result of a sum formula.
I have tried "Worksheet_Change(ByVal Target As Range)"
and "Worksheet_SelectionChange(ByVal Target As Range)'
Both of which don't update when C9 updates.
1- Using this code below works, but with a minor problem. If i delete a
row or something like that then
the code runs, i assume cause the worksheet recalculates. A way to fix
that?
2- Also i don't want the "little speaker shape" to be visible on the
worksheet. Is there a better way than
the way i have below? It seems, it has to be visible in order to play.
3- A way to embed the wav in the workbook instead of the active sheet?
IE: so it can be called from
multiple worksheets, but not go to another worksheet.
Thx for any direction.
Code:
--------------------
Private Sub Worksheet_Calculate()
If Range("C9") > 100 Then
Call MyMacro
End If
End Sub
Sub MyMacro()
ActiveSheet.Shapes("Object 1").Visible = True
ActiveSheet.Shapes("Object 1").Select
Selection.Verb Verb:=xlPrimary
ActiveSheet.Shapes("Object 1").Visible = False
Range("D1").Activate
End Sub
In Cell C9 is the result of a sum formula.
I have tried "Worksheet_Change(ByVal Target As Range)"
and "Worksheet_SelectionChange(ByVal Target As Range)'
Both of which don't update when C9 updates.
1- Using this code below works, but with a minor problem. If i delete a
row or something like that then
the code runs, i assume cause the worksheet recalculates. A way to fix
that?
2- Also i don't want the "little speaker shape" to be visible on the
worksheet. Is there a better way than
the way i have below? It seems, it has to be visible in order to play.
3- A way to embed the wav in the workbook instead of the active sheet?
IE: so it can be called from
multiple worksheets, but not go to another worksheet.
Thx for any direction.
Code:
--------------------
Private Sub Worksheet_Calculate()
If Range("C9") > 100 Then
Call MyMacro
End If
End Sub
Sub MyMacro()
ActiveSheet.Shapes("Object 1").Visible = True
ActiveSheet.Shapes("Object 1").Select
Selection.Verb Verb:=xlPrimary
ActiveSheet.Shapes("Object 1").Visible = False
Range("D1").Activate
End Sub