EXCEL追加Botton

来源:互联网 发布:软件工程质量 编辑:程序博客网 时间:2024/05/21 19:46






**********************************************************************************************************************************************

Private Sub CommandButton1_Click()


Dim strValue As String


'使用某个sheet中的控件,必须选中对应sheet,取得控件对象


strValue = Application.ActiveSheet.TextBox1.Value


MsgBox strValue
End Sub

**********************************************************************************************************************************************


结果:



0 0