Click here to Skip to main content
15,909,325 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
i have one combobox and a text box ...how can i fetch data automatically to the textbox when selecting a value from combobox ,Iam following multi=tier architecture
Posted
Comments
Ramug10 4-Apr-14 8:34am    
do you need to display combobox selected value in textbox? it's quite simple task you can write combobox selectedIndexChanged event.
or
you looking any other??

Solution:
there is event in combobox '
C#
private void ComboBox1_SelectedIndexChanged(object sender,
        System.EventArgs e)

'

Put your code to fetch data into this even.

Detailed Description: Combobox Even
 
Share this answer
 
C#
private void comboBox1_SelectedIndexChanged(object sender, EventArgs e)
        {
            textBox1.Text = comboBox1.SelectedItem.ToString();
        }
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900