Here is an example of VBA running on a particular cell change:
http://www.mrexcel.com/forum/showthread.php?t=521405
Input your code into the Worksheet Module of the Worksheet you are working with.
Right click sheet tab
Click "View Code"
Paste the code into the panel that opens. ("WorkSheet" Module)
Alt-Q to quit the VBA Editor.
Just change the procedure name
Code:Private Sub Worksheet_SelectionChange(ByVal Target As Range)
use Intersect or similar to define ranges if needed, same as you would with a value change.
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Target.Count > 1 Then Exit Sub
If Intersect(Target, Range("D4:D79")) Is Nothing Then Exit Sub
Application.EnableEvents = False
If vbYes = MsgBox("Current Value: " & Target.Value & vbCrLf & _
"Click Yes to increase to: " & Target.Value + 1, vbYesNo + vbInformation, _
"Increase?") Then Target.Value = Target.Value + 1
Application.EnableEvents = True
End Sub
Private Sub Worksheet_Change(ByVal Target As Range)
Dim rng As Range
'Only look at single cell changes
If Target.Count > 1 Then Exit Sub
'Set the range to trigger the InputBox
Set rng = Range("C8:C30")
'Only look at that range
If Intersect(Target, rng) Is Nothing Then Exit Sub
'Your code here...
End Sub