How to fill a combobox from a spreadsheet, then put user input text box value on same line in same sheet

dappelma

New Member
Joined
Feb 14, 2013
Messages
1
I hope I've included enough information, this my first time posting any question, so please let me know if i've not done something correct, and thank you in advance for help. Version Excel 2010


I have a spreadsheet called "Information", with the columns ID NUmber, Name, organization, units planned, units completed


I have a userform that fills out the first three columns at the beginning of a cycle.
I have a second user form ("DataInput"), with a combobox (CmbxIDNunber), that has a row source of Information B1:B10000
, and a textbox "TxtBxCompletedUnits"

Using the form Data Input, based on the user selection in "CmbxIDNumber" i can get the form to autofill the organization and units planned from the same row as "CmbxIDNumber", but i would like to have the information the user puts in to TxtBxCompletedUnits in the column Units Completed in Worksheet "Information".

Name is not a unique value, it can be repeated many times, but with different values in the other columns.

I'm using the following to fill in the first columns from the DataInput form to Information, but i cannot seem to figure out what to do to have the information from TxtbxCompletedunits be put in the corresponding field on the "Information" worksheet:

Private Sub CmbxIDNumber_Change()
TxtBxCompletedUnits.Value = ""
With CmbxIDNumber
TxtBxName.Text = WorksheetFunction.Index(Range(.RowSource).Offset(, 1), .ListIndex + 1)
TxtBxOrg.Text = WorksheetFunction.Index(Range(.RowSource).Offset(, 2), .ListIndex + 1)
TxtBxUnitsPlanned = WorksheetFunction.Index(Range(.RowSource).Offset(, 3), .ListIndex + 1)

End With



End Sub

There is a "Submit" button the user form and i'd like the information tranferred when the button is clicked
 
Last edited:

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off

Forum statistics

Threads
1,214,833
Messages
6,121,868
Members
449,053
Latest member
Mesh

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