Skip to content

GRIDVIEW COMBO and Button

newto net

Asked Mar 15, 2012, 10:08 AM EDT2 answers
Share
LinkedInX
Hi
My requirement

Table 1 --- CountryList

Country
India
Australia
Srilanka
Table 2 --- CountryInfo
Country
Info


I need to implement this column field Country from the table CountryList in the gridview with each row Combo box & button generation and If i select any country from combo box and clicked the button means It will show the selected country info from the CountryInfo table. Country and Country are relation ship with each other.

Please let me know

2 Answers

Know the answer? Post it. Somebody with the same question will find it here.

  • Senthilkumar
    0
    Hi,

    Place the dropdownlist control in the template field. Write the rowdatabound event and identify the dropdown list and bind the countrylist table result to the dropdownlist control.

    Write the commandname to the button control and write the itemcommand event and check the button command name and identify get the value from the dropdownlist control.

    Now you can perform the countryinfo table based on the selected item in the country list.
    0
  • 0
    Thanks senthil, Can you share me the code here about the item command event and button command name. I need to output in another grid. and I need to load the column in dropdown list at page load.
    0