updatepanel回发后无法从外部文件运行Javascript方法 [英] Can't run Javascript method from external file after updatepanel postback

查看:67
本文介绍了updatepanel回发后无法从外部文件运行Javascript方法的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,



在updatepanel回发后无法从外部文件运行Javascript方法。

我使用了ScriptManager.RegisterClientScriptInclude方法:

Hi All,

Can't run Javascript method from external file after updatepanel postback.
I used the ScriptManager.RegisterClientScriptInclude method:

ScriptManager.RegisterClientScriptInclude(updatePanel, updatePanel.GetType(), "a_key", "myScript.js");





但它不起作用。有可能吗?



先谢谢



But It doesn't work. Is there any possibility?

Thanks in Advance

推荐答案

当你打电话给你的js时,不确定你是否遇到问题(如果是这种情况,请通过浏览器开发人员工具查看控制台以检查错误),或者您希望在更新后运行一块js,但事实并非如此。对于那个问题,这个主题包括在updatepanel回发上运行js。



如何在updatepanel执行完成后运行javascript [ ^ ]
Not sure if you are having a problem when you call your js (if that is the case look at the console via the browser developer tools to check for errors), or that you want a piece of js to run after an update but it isn't. For that issue this thread covers running js on updatepanel postbacks.

How to run javascript after updatepanel execution completed[^]


这篇关于updatepanel回发后无法从外部文件运行Javascript方法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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