VBA中MsgBox的几个用法

1.简单的弹出一个消息

MsgBox ("Common Msg")

VBA中MsgBox的几个用法_第1张图片

2.显示某个单元格的信息

MsgBox "Cell A1 is " & Range("A1").Value
VBA中MsgBox的几个用法_第2张图片

3.加入换行

MsgBox "Line 1 Content" & vbNewLine & "Line 2 Content"

VBA中MsgBox的几个用法_第3张图片


你可能感兴趣的:(VBA中MsgBox的几个用法)