如何使用C#使用Bootstrap实现部分页面回发缓存 [英] How Do I Achieve Partial Page Postback Caching Using Bootstrap With C#
本文介绍了如何使用C#使用Bootstrap实现部分页面回发缓存的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我只需在Web窗体中创建一个TextBox并设置其属性,例如AutoPostBack = true,并在文件后面的代码中为其TextChanged事件写一个函数
这是我的TextBox的代码
I simply create a TextBox in a Web Form and set its property such as AutoPostBack=true and write a one function on its TextChanged Event in a code behind files
Here Is code For my TextBox
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<ContentTemplate>
<div class="form-group col-md-12">
<label>Basic Salary : </label>
<asp:TextBox ID="txt_basic_salary" runat="server" CssClass='form-control addition'
placeholder="Basic Salary" TabIndex="4" AutoPostBack="True"
ontextchanged="txt_basic_salary_TextChanged"></asp:TextBox>
</div>
</ContentTemplate>
</asp:UpdatePanel>
这里是代码隐藏文件中我的TextChanged事件的代码
Here a code for my TextChanged Event in a code behind file
protected void txt_basic_salary_TextChanged(object sender, EventArgs e){
// do something
}
请提前修改我的上述代码,提前感谢你的答案
Please suggest the corrections with my above code thanks in advance for your answers
推荐答案
你添加了scriptmanager
然后所有的事情似乎都设定好了。现在,您可以在下拉事件更改中添加逻辑。
have u added scriptmanager
then all things seems to be set. Now u can add logic in your dropdown event change.
这篇关于如何使用C#使用Bootstrap实现部分页面回发缓存的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文