我想禁用标签 [英] i want to disable label

查看:64
本文介绍了我想禁用标签的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

朋友们,大家下午好。我正在使用asp.net标签显示消息,但是我需要自动显示false标签。标签在updatepanel中有更新面板我正在使用脚本我可以禁用消息但是在使用时ajax不工作可以任何人说我该怎么做.....

hi friends good afternoon every one.i am displaying message using asp.net label but i need to visible false the label automatically.The label is in updatepanel with out update panel i am using script i can disable the message but while using ajax it is not working can any one say how can i do it.....

推荐答案

Label1.Visible = false;
UpdatePanel1.Update();


我理解的是,你在页面加载时或在回发之前使用javascript隐藏标签但是javascript相同回发后没有工作。

如果是这种情况,那么将你的javascript保存在下面的add_endRequest函数中并检查。

What i am understanding is ,you are hiding the label when page loads or before postback using javascript but same javascript is not working after postback.
if this is the case then keep your javascript inside the following add_endRequest function and check.
<script type="text/javascript">

               var prm = Sys.WebForms.PageRequestManager.getInstance();
               prm.add_endRequest(function () {
     //put your javascript here to hide the label
 });
                
            </script>







谢谢

快乐编码




Thanks
Happy coding


http:/ /asp-net-example.blogspot.in/2009/03/how-to-show-hide-visible-label.html [ ^ ]

http://stackoverflow.com/questions/4876638/disabling-an-asp-net-标签 - 来自客户端 [ ^ ]

^ h ttp://stackoverflow.com/questions/3297750/how-to-hide-label-in-asp-net [ ^ ]
http://asp-net-example.blogspot.in/2009/03/how-to-show-hide-visible-label.html[^]
http://stackoverflow.com/questions/4876638/disabling-an-asp-net-label-from-client-side[^]
http://stackoverflow.com/questions/3297750/how-to-hide-label-in-asp-net[^]


这篇关于我想禁用标签的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆