【问题标题】:PageMethods.set_path does not work in urlrewritingPageMethods.set_path 在 urlrewriting 中不起作用
【发布时间】:2012-11-23 13:50:51
【问题描述】:

我有一个通过 Javascript 函数调用单个 PageMethod 的测试 Web 应用程序。

PageMethods.myMethod(params, onSuccess, onFailed);

当我使用 urlRewriting 时,它不再起作用。所以,我搜索了网页,我发现这个要添加到 js 文件中。

Pagemethods.set_path("/the_real_path.aspx");

但是这不起作用。当我用 F12 查看 chrome 中的 web 开发人员工具时,它给出了 404 not found 错误。

你有什么建议吗?任何帮助将不胜感激

下面已经完成了。

-ScriptManager EnablePageMethods = True
-Method is public and shared(static)
-Method is decorated with <WebMethod(True)>

【问题讨论】:

    标签: asp.net url-rewriting webmethod pagemethods


    【解决方案1】:

    无论如何,我找到了另一种方式来拨打WebMethod。我使用了网络服务。我不需要使用 PageMethods。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2016-10-28
      • 1970-01-01
      • 2011-05-19
      • 1970-01-01
      • 1970-01-01
      • 2019-08-27
      • 2014-09-02
      • 1970-01-01
      相关资源
      最近更新 更多