I want to select data from the SqlDataSource tag on Gridview using TextBox1 value. How can I modify the ASP.net code behind the file.
& lt; asp: SqlDataSource ID = "SqlDataSource1" runat = "server" selectcommand = Select "different [species], [amount], [Vw_getFishDtls] from [Tank_aidi] = TextBox1.Text and [ftype] = ([vw_getFishType] from [Ftype] select where [get], [Delete], [death], [dispatch], [dispatch], [Deepitisals] where [Tank_aidi] = textbox 1. text "connection string =" data source = IT-Aishan; early catalog = ETF; user ID = ishanuk77; password = Aishanuk 77; "& gt; and lt; / ASP: Skyueldiattisosaar & gt; You can add the ControlParameter
& lt; Asp: SqlDataSource ID = "SqlDataSource1" runat = "server" SelectCommand = "different [species], [amount], [get], [discard], select the [Mntrta], [dispatch], [dispatch], [Deepiti_sles] [Vw_getFishDtls] where [Tank_id] = TextBox1.Text and [ftype] = (select [vw_getFishType] [ftype] where [Tank_id] = @ Tank_id "ConnectionString =" data source = IT ISHAN; Initial catalo G = ETF; User id = ishanuk77; Password = ishanuk77; & Gt; selectParameters & gt; ASP: Control parameter control id = "textbox1" name = "tank_id" property name = "text" /> gt; & lt; / selectParameters & gt; & lt; / asp: SqlDataSource & Gt;
Comments
Post a Comment