填充下拉列表中的文本框在asp.net中选择 [英] Populate text boxes on dropdownlist select in asp.net
本文介绍了填充下拉列表中的文本框在asp.net中选择的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我是asp.net的新手。我有一个下拉列表,后面填充了代码。当我从下拉列表中选择任何项目时,它应该根据表格中的数据填充两个文本框和另一个下拉列表。
I am new at asp.net. I have a dropdownlist which is populated in code behind. When I select any item from dropdownlist, it should populate two textbox and another dropdownlist according to data from table.
<asp:DropDownList runat="server" ID="dropDownExisting"></DropDownList><br />
<asp:TextBox ID="txtPromotion" runat="server" Width="77px" ></asp:TextBox><br />
<asp:TextBox ID="txtSubject" runat="server" Width="288px"></asp:TextBox><br />
<asp:DropDownList ID="dropDownType" runat="server">
<asp:ListItem>Monthly Newsleter</asp:ListItem>
<asp:ListItem>Webbinar Newsleter</asp:ListItem>
<asp:ListItem>Annoucement</asp:ListItem>
</asp:DropDownList>
我希望它能在客户端完成。我在哪里提供数据库连接?我是否需要像更新面板一样使用ajax控件?或者javascript会运行良好吗?我不希望发生回发。我想在客户端。
I want it to be done on client side. Where do I have to provide database connectivity? Do I require to use ajax control like update panel? Or javascript will work well? I don't want postback to happen. I want on client side.
推荐答案
您可以使用ajax
按照您的要求执行。
请查看已解决的问题 HERE
并进一步帮助链接可以找到 这里的
希望它会有所帮助。 :)
You can useajax
to perform as per your requirement.
Kindly have a look at solved question HERE
and further helping links can be found HERE
Hope it will help. :)
我很漂亮和这里。这正是我想要的
I got beautiful ans Here.This is exactly what I wanted
这篇关于填充下拉列表中的文本框在asp.net中选择的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文