I was wondering how to insert data (numbers) from a combobox into a spreadsheet underneath the column specified by a different combobox, which is a text. For instance, I have one combobox in which the user selects a customer, and another combobox where the user enters a part number. The customer names are in the first row of a sheet and I want the part numbers to appear below that customer name chosen, by smallest to largest and underneath the already present part #'s. As of now I have this, but I know it's wrong.
idx = ComboBox1.Text
Set rngParts = .Range(.Cells(2, idx + 1), .Cells(LastRow, idx + 1))
With Sheets("Metallize")
Unload NewPartNumUF
Sheets("Metallize").Select
RowNum = .Cells(Rows.Count, 1).End(xlUp).Offset(1, 0).Row
Cells(RowNum, idx) = TextBox1.Value
Unload NewPartNumUF
Worksheets("Metallize").Activate
End With
Bookmarks