G
Guest
Hi Everyone,
I'm having a problem trying to get the program to execute the
SelectedIndexChanged event for a Dropdownlist (Combobox). I double clicked
the control to get the event in the Code-Behind file. I have the following
declare :
Protected Sub cmbPORequests_SelectedIndexChanged(ByVal sender As Object,
ByVal e As System.EventArgs) Handles cmbPORequests.SelectedIndexChanged
if cmbPORequests.SelectedValue > 0 then
BindGrid(cmbPORequests.SelectedValue )
end if
End Sub
When I select a new item in the control, the event is not executed. I even
tried to add the following to the markup:
<aspropDownList ID="cmbPORequests" runat="server" DataTextField=""
OnSelectedIndexChanged="cmbPORequests_SelectedIndexChanged"
DataValueField="" Style="left: 298px; top: 109px" Width="175px">
</aspropDownList>
This didn't work either. One question I did have was: Do I need to set the
AutoPostBack property to true? From my reading I get the feeling I don't need
to, but wanted to make sure. Any comments would help. Thanks.
Michael
I'm having a problem trying to get the program to execute the
SelectedIndexChanged event for a Dropdownlist (Combobox). I double clicked
the control to get the event in the Code-Behind file. I have the following
declare :
Protected Sub cmbPORequests_SelectedIndexChanged(ByVal sender As Object,
ByVal e As System.EventArgs) Handles cmbPORequests.SelectedIndexChanged
if cmbPORequests.SelectedValue > 0 then
BindGrid(cmbPORequests.SelectedValue )
end if
End Sub
When I select a new item in the control, the event is not executed. I even
tried to add the following to the markup:
<aspropDownList ID="cmbPORequests" runat="server" DataTextField=""
OnSelectedIndexChanged="cmbPORequests_SelectedIndexChanged"
DataValueField="" Style="left: 298px; top: 109px" Width="175px">
</aspropDownList>
This didn't work either. One question I did have was: Do I need to set the
AutoPostBack property to true? From my reading I get the feeling I don't need
to, but wanted to make sure. Any comments would help. Thanks.
Michael