PDA

View Full Version : [SOLVED:] Help with userform combobox and Excel



SUJU
10-18-2004, 06:01 PM
Hi
I have a userform that has a few comboboxes. Each combobox has several option from which, once clicked, requests data from an API data field. This data is then fed back to my Excel spreadsheet. Myquestion: How do I get excel to change the name of its header column to equal that chosen in the userform. Thus, if I choose "Div Yield", then the name at the top of column C5 should change to Div Yield as well. But must be allowed to change if another option is chosen later.
Hope I have made myself clear.

Thanx

mark007
10-19-2004, 03:58 AM
I'm not entirely clear what you are after but I think what you want is comething like:



Private Sub Combo1_Change()
thisworkbook.sheets("Lists").Range("a1").value=Combo1.Text
End Sub


i.e. Just set the value of the relevant cell when the combo changes.

:)