[英]Geting textbox value in msgbox excel VBA
I want a message box to appear after someone has entered a wrong value For example: 我希望有人输入错误的值后出现一个消息框,例如:
Msgbox("The value ""txtID"" is wrong")
So if i typed the wrong value the message box should say "The value 200(for example) is wrong" . 因此,如果我输入了错误的值,则消息框应显示“值200(例如)错误”。 How can i do that?
我怎样才能做到这一点?
Anything within double quotes will be considered as a string. 双引号内的任何内容都将被视为字符串。 Try this.
尝试这个。
Msgbox("The value " & txtID & " is wrong")
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.