将文本框值放入变量

问题描述 投票:0回答:1

我想在按下按钮后将GUI TextBox中的值保存到变量中。

到目前为止,我的代码:

    Dim TestSpalte As Long
    TestSpalte = TextBox1.Value
    MsgBox "Test " & TestSpalte

谢谢!

excel vba textbox
1个回答
0
投票

替换:

Dim TestSpalte As Long

with:

Dim TestSpalte As String
© www.soinside.com 2019 - 2024. All rights reserved.