Private Sub Worksheet_SelectionChange(ByVal Target As Range)
'以单元格进入代替按钮对象调用宏
If Range("$A$1") = "关闭" Then Exit Sub
Select Case Target.Address
Case "$A$5" '单元地址(Target.Address),或命名单元名字(Target.Name)
Call 宏1
Case "$B$5"
Call 宏2
Case "$C$5"
Call 宏3
End Select
End Sub |
|
susan