| | |
SelectedIndexChanged not firing for dropdownlist
Please support our ASP.NET advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Sep 2007
Posts: 23
Reputation:
Solved Threads: 0
For some reason, selectedindexChanged vb.net code is no longer firing. autopostback and enable viewstate are sill true. Enabled is set to true in code behind. Using VS2008.
Any idea on what can cause this?
Thanks,
Randy
Any idea on what can cause this?
Thanks,
Randy
ASP.NET Syntax (Toggle Plain Text)
<asp:DropDownList id="ddlEmpName2" style="Z-INDEX: 138; LEFT: 192px; POSITION: absolute; TOP: 32px" runat="server" Width="152px" ForeColor="DarkBlue" DataValueField="EmployeeId" DataTextField="EmpLastFirst" DataSource="<%# dvEmpActiveList %>" Font-Size="X-Small" AutoPostBack="True" Enabled="False" AppendDataBoundItems="True" <asp:ListItem Selected="false" Text="Select" Value="0"></asp:ListItem> </asp:DropDownList>
•
•
Join Date: Sep 2007
Posts: 23
Reputation:
Solved Threads: 0
Thanks for the quick response,ninjaimp.
The session variable was set up to try to hold the info for the update, but the method does NOT fire
Public Sub ddlEmpName2_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles ddlEmpName2.SelectedIndexChanged
SelectedEmpId = ddlEmpName2.SelectedValue
Session("ddlEmpName2Session") = ddlEmpName2 '[4-29-2009]
lblOrgNameShort_DataBinding(Me, e)
SetActiveOrg(drOrg)
End Sub
The session variable was set up to try to hold the info for the update, but the method does NOT fire
Public Sub ddlEmpName2_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles ddlEmpName2.SelectedIndexChanged
SelectedEmpId = ddlEmpName2.SelectedValue
Session("ddlEmpName2Session") = ddlEmpName2 '[4-29-2009]
lblOrgNameShort_DataBinding(Me, e)
SetActiveOrg(drOrg)
End Sub
•
•
Join Date: Sep 2007
Posts: 23
Reputation:
Solved Threads: 0
•
•
•
•
Hi Randy
There is no event selected in the HTML - runat Server is good but what sub are you going to call.
I think you have probably copied this control from another page - been there done it. Try double clicking the control and you should be fine.
This was existing logic. When I double-click on the control, it creates the selectedIndexChanged sub, but does NOT reference the sub in the aspx file -- I guess because it's using the default name.
I have another ddl on the page, and it works correctly, though it does NOT have autopostback set. It also does not mention the sub in the aspx.
I'm still open to suggestions...
![]() |
Similar Threads
- dropdownlist not firing (VB.NET)
Other Threads in the ASP.NET Forum
- Previous Thread: remote access
- Next Thread: filter on gridview
| Thread Tools | Search this Thread |
.net 2.0 3.5 activexcontrol advice ajax appliances asp asp.net bc30451 beginner bottomasp.net browser businesslogiclayer button c# c#gridviewcolumn cac checkbox class click commonfunctions compatible confirmationcodegeneration content contenttype control countryselector courier css database datagrid datagridview datagridviewcheckbox datalist deadlock deployment development dgv dialog dropdownmenu dynamic edit embeddingactivexcontrol expose findcontrol flash flv formatdecimal forms formview gridview homeedition iframe iis javascript jquery list menu mono mssql multistepregistration nameisnotdeclared novell objects order problem ratings rotatepage save search security serializesmo.table sessionvariables silverlight smartcard sql sqlserver2005 ssl suse textbox tracking treeview unauthorized validatedate validation vb.net video virtualdirectory vista visual-studio visualstudio vs2008 web webarchitecture webdevelopemnt webdevelopment wizard xml youareanotmemberofthedebuggerusers





