Developing USERFORMS

rhino4eva

Active Member
Joined
Apr 1, 2009
Messages
260
Office Version
  1. 2010
Platform
  1. Windows
i have seen tutorials on how to set a userform to setup a database style worksheet ... but i need to move on a little to achieve my goal.

my userform consists of a combo box with 3 choices named the same as 3 worksheets with the same book.
under which is a text box for the date and 2 other test boxes for numeric results
and a submit command button

what i need to know is how to slot the date/result boxes in to the named sheet/s when the submit button is pressed.
the format of each of the worksheets is identical so as to eliviate any mapping problems

i would appreciate any help with this

Adam
 

Excel Facts

Copy PDF to Excel
Select data in PDF. Paste to Microsoft Word. Copy from Word and paste to Excel.
Theres not much to go one there but maybe this may help:

Code:
Set sh = Sheets(Combobox1.Value)

With sh
    .Range("A" & .Rows.Count).End(xlUp).Offset(1) = TextBox1.Text
End With
 
Last edited:
Upvote 0
Try something like this:
Code:
Private Sub CommandButton2_Click()
Sheets(ComboBox1.Value).Range("A1").Value = TextBox1.Value
Sheets(ComboBox1.Value).Range("B1").Value = TextBox2.Value
End Sub
 
Upvote 0

Forum statistics

Threads
1,215,066
Messages
6,122,948
Members
449,095
Latest member
nmaske

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top