Userform with textbox displaying Cell B1 Value

J

JMay

How do I do this?

My Cell B1 contains the number 55.

I want my textbox to read

"Cell B1 is 55",

But HOW???????????
 
P

Per Jessen

You can load the textbox when the userform is initialezed. Ínsert the
code below in the code sheet for for the userform.

Private Sub UserForm_Initialize()
Me.TextBox1.Value = "Cell B1 is " & Range("B1").Value
End Sub

Regards,
Per
 
C

Chip Pearson

Try something like

Me.TextBox1.Text = "Cell B1 is " & Format(Range("B1").Value,"#,##0")

Cordially,
Chip Pearson
Microsoft Most Valuable Professional
Excel Product Group, 1998 - 2010
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)
 
Top