View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.programming
Rick Rothstein Rick Rothstein is offline
external usenet poster
 
Posts: 5,934
Default COMBOBOX AND TEXTBOXES QUESTION !!

This is a perfect example of why people posting questions on newsgroups
should *not* simplify their questions for us... our answers (code and/or
formulas) are highly dependent on the layout they will be applied against...
when you simplify your question, you end up getting an answer to a question
that doesn't really apply to what you need. Fortunately, the modification
needed for your actual layout is easy enough to implement; we just have to
adjust the relationship between the ListIndex value and the row number
offset to the start of your data. Try this...

Private Sub ComboBox1_Change()
TextBox1.Value = Worksheets("TEST").Cells(ComboBox1.ListIndex + 2, "B")
TextBox2.Value = Worksheets("TEST").Cells(ComboBox1.ListIndex + 2, "C")
End Sub

--
Rick (MVP - Excel)


"jay dean" wrote in message
...
I actually loaded the data from Range("A2:A250"), that is, I did not
start from A1. This should not be an issue right?



*** Sent via Developersdex http://www.developersdex.com ***