Valua of a cel as message in a MsgBox

R

Reijer

Hello Excellers,

How can i assign a valua (text) that is in cel B2 of an active sheet to a
part of the message of a MsgBox ?

Thanks for your attention,
Greetz Reijer.
 
D

Don Guillett

Sub textinmsgbox()
MsgBox "start of msg " & Range("k1") & " end of msg"

End Sub
 
G

Gord Dibben

Sub test()
dim myval as string
myval = Range("B2").Value 'or .Text
MsgBox "The value is " & myval
End Sub


Gord Dibben MS Excel MVP
 
Top