2013-03-15 57 views
0

我使用DNN 6.0和VS2008 AjaxControl工具箱3.5AutoCompleteExtender在DotNetNuke的

我想ASP.NET AutoCompleteExtender添加到一个文本框在我的DNN模块中的一个不工作。

据我所知,AutoCompleteExtender只能通过web服务工作。

我已经添加了一个web服务,但我无法使AutoCompleteExtender工作,我没有得到任何错误,但web服务从未被调用,我缺少什么或者如何让ASP.NET AutoCompleteExtender工作?

谢谢

回答

1

在我的情况下,它是下列问题:

错误味精:与类定义[ScriptService]属性只有Web服务可以从脚本中调用。

尝试将[ScriptService]作为您的Web服务类的定义。 例如:

[WebService(Namespace = "http://dnndev/")] 
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)] 
[System.ComponentModel.ToolboxItem(false)] 
[ScriptService] 
// To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line. 
// [System.Web.Script.Services.ScriptService] 
public class BusinessDataProvider : System.Web.Services.WebService 
{ 

    [WebMethod] 
    [ScriptMethod]   
    public string[] GetSpecificListOfContributors(string prefixText, int count) 
    { 
     return ContributorController.GetSpecificListOfContributors(prefixText, count); 
    } 
} 

我希望这一个会帮助你。

最好,

+0

谢谢,我明白了@ Phantom – Gajawada 2013-04-22 04:12:18