ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   link a cell into a vba form (https://www.excelbanter.com/excel-programming/280638-link-cell-into-vba-form.html)

newman

link a cell into a vba form
 
I have create a simple for for the user to enter three
variables. What I want to is to have that information go
into a particular cell. Can anyone tell me how to link
that infoprmtion entered from the form to the cell in the
worksheet

Regards

Newman


Tom Ogilvy

link a cell into a vba form
 
You can't link three textboxes to a single cell in a meaningful way. Link
each to a separate cell, then use a fourth cell to combine the information
if that is what you need. In the property of each textbox, under the
controlsource property, put in an entry like

Sheet1!A1

--
Regards,
Tom Ogilvy


newman wrote in message
...
I have create a simple for for the user to enter three
variables. What I want to is to have that information go
into a particular cell. Can anyone tell me how to link
that infoprmtion entered from the form to the cell in the
worksheet

Regards

Newman




No Name

link a cell into a vba form
 
Tom

Thank you I worked that one out is it possible to turn
that text input to a date selection rop down box

Regards

Newman
-----Original Message-----
You can't link three textboxes to a single cell in a

meaningful way. Link
each to a separate cell, then use a fourth cell to

combine the information
if that is what you need. In the property of each

textbox, under the
controlsource property, put in an entry like

Sheet1!A1

--
Regards,
Tom Ogilvy


newman wrote in message
...
I have create a simple for for the user to enter three
variables. What I want to is to have that information go
into a particular cell. Can anyone tell me how to link
that infoprmtion entered from the form to the cell in

the
worksheet

Regards

Newman



.


Tom Ogilvy

link a cell into a vba form
 
Assuming a combobox from the control toolbox toolbar on a worksheet.

Private Sub CommandButton2_Click()
Dim cbox As MSForms.ComboBox
Dim ctrl As MSForms.Control
Set cbox = ActiveSheet.OLEObjects("Combobox1").Object
cbox.Clear
For Each ctrl In UserForm1.Controls
If TypeOf ctrl Is MSForms.TextBox Then
Set tbox = ctrl
If Len(Trim(tbox.Text)) < 0 Then
If IsDate(tbox.Text) Then
cbox.AddItem tbox.Text
End If
End If
End If
Next

End Sub


--
Regards,
Tom Ogilvy



wrote in message
...
Tom

Thank you I worked that one out is it possible to turn
that text input to a date selection rop down box

Regards

Newman
-----Original Message-----
You can't link three textboxes to a single cell in a

meaningful way. Link
each to a separate cell, then use a fourth cell to

combine the information
if that is what you need. In the property of each

textbox, under the
controlsource property, put in an entry like

Sheet1!A1

--
Regards,
Tom Ogilvy


newman wrote in message
...
I have create a simple for for the user to enter three
variables. What I want to is to have that information go
into a particular cell. Can anyone tell me how to link
that infoprmtion entered from the form to the cell in

the
worksheet

Regards

Newman



.





All times are GMT +1. The time now is 06:55 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com