Text box help

G

Greg B...

I want to make a splash screen with text box 1 showing the contents of cell
c 12 on my worksheet


How do I code this please

Thanks in advance

Greg
 
B

Bob Phillips

Create a userform, and add a textbox and this code

Private Sub UserForm_Activate()
TextBox1.Text = Worksheets("Sheet1").Range("C12").Value
Application.OnTime Now + TimeSerial(0, 0, 5), "CloseForm"
End Sub

and in a general code module add this

Sub CloseForm()
Unload UserForm1
End Sub

This will display the form for 5 seconds

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
Top