I’m developing a web application in visual studio 2010.
I’ve a list view and want the list box selectindexchange event to be fired when the user select a different item. but it is not working, as the page is not even refreshing. am i missing something?
Just to add some clarity to this question for future references:
- I was using C#
- Using a List Box from the visual studio toolbox.
<asp:ListBox ID="ListBox1" runat="server"
onselectedindexchanged="ListBox1_SelectedIndexChanged" AutoPostBack="True"></asp:ListBox>
Under the Properties of the ListBox1, the SelectedIndexChanged property is set to ListBox1_SelectedIndexChanged.
protected void ListBox1_SelectedIndexChanged(object sender, EventArgs e)
{
...some logic here...
}
May be left
autopostback="true".