| View previous topic :: View next topic |
| Author |
Message |
mouli
Joined: 24 Aug 2007 Posts: 84
|
Posted: Wed Oct 22, 2008 7:20 am Post subject: Problem with dropdownlist |
|
|
Hi all,
In my project, i am binding data to dropdownlist control using sqldata source. In my code when i set the selected text for dropdownlist as
dropdownlist1.SelectedItem.Text = "value";
the item i have selected through my code is getting bind to dropdownlist control two times. can any one give me solution to my problem.
Mouli.
Last edited by mouli on Wed Oct 22, 2008 7:29 am; edited 1 time in total |
|
| Back to top |
|
 |
vinay
Joined: 28 Aug 2007 Posts: 95
|
Posted: Wed Oct 22, 2008 7:27 am Post subject: |
|
|
Hi Mouli,
Instead of using selectedtext property, use SelectedValue property of dropdownlist control
dropdownlist1.SelectedValue = value;
Post me if you have any issue ...
Vinay. |
|
| Back to top |
|
 |
|