Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
You want to use the Initialize event for the userform.
The code would be something like this: Private Sub UserForm_Initialize() TextBox1.Text = Worksheets("Sheet1").Range("A1").Value End Sub You will need to use the actual names for your textbox and worksheet. -----Original Message----- Dear VBA Experts, I have a UserForm where I want to have a textbox populated with an amount in a cell. I have tried the ControlSource = the cell or the Value = the cell and am getting an error message. Assuming I have a number in cell A1, what is the code to have that info populate a textbox in a userform so that when the userform is opened, the textbox already shows that amount? Thanks in advance. Neal . |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
WordWrap a TextBox on a UserForm | Excel Discussion (Misc queries) | |||
Userform with textbox displaying Cell B1 Value | Excel Discussion (Misc queries) | |||
Add COUNTIF TO USERFORM TEXTBOX | Excel Worksheet Functions | |||
Userform with 5 textbox and 1 needs to refresh to have total | Excel Discussion (Misc queries) | |||
userform textbox | Excel Worksheet Functions |