SQL Server 2005General discussion of SQL Server *2005* version only.
Welcome to the p2p.wrox.com Forums.
You are currently viewing the SQL Server 2005 section of the Wrox p2p Programmer to Programmer discussion community. This is a community of more than 40,000 computer programmers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining our free Wrox p2p community you can post your own programming questions and respond to other programmers’ questions. Registered users also don't have to see the ads that are displayed to guests. Registration is fast, simple and absolutely free so please, join today!
Join today and post to win prizes! Post more to increase your chances of being Wrox’s top poster of the month.
Good afternoon,
I am writing a web application using visual web developer and while trying to create a dynamic dropdown using the SqlDataSource i am getting these errors when i try to correct either one:
'SqlDataSource1_Selecting' is not a member of 'ASP.testdirectortest_aspx
and
Control 'DropDownList1' of type 'DropDownList' must be placed inside a form tag with runat=server.
Anyone ever seen this before?
Here is the code i am trying to use:
<asp:SqlDataSource ID="SqlDataSource2" runat="server" ConnectionString="<%$ ConnectionStrings:test1ConnectionString %>"
OnSelecting="SqlDataSource1_Selecting" SelectCommand="SELECT [TEST_FACILITY] FROM [Test_Facility_Data]">
</asp:SqlDataSource>
<asp:DropDownList ID="DropDownList1" runat="server" AutoPostBack="True" DataSourceID="SqlDataSource2"
DataTextField="TEST_FACILITY" DataValueField="TEST_FACILITY" OnSelectedIndexChanged="DropDownList1_SelectedInde xChanged1">
</asp:DropDownList>