Public Function PictureOrButton(ByRef Obj ) as Boolean
If TypeOf Obj Is PictureBox Then
MsgBox "PictureBox"
ElseIf TypeOf Obj Is CommandButton Then '这行刚才写错了
MsgBox "按扭"
End If
Public Function PictureOrButton(ByRef Obj ) as Boolean
If TypeOf Obj Is PictureBox Then
MsgBox "PictureBox"
ElseIf TypeOf Obj Is Command Then
MsgBox "按扭"
End If