AJAX Autocomplete Extender problem

S

Stefan Filip

Hello,

I have an ajax autocomplete extented on a page and it works just fine in the
ASP .net Development Server, but after I put it on an IIS server it doesn't
work anymore. Here's the code I have:

Start.aspx:
<ajaxToolkit:AutoCompleteExtender
runat="server"
BehaviorID="AutoCompleteEx"
ID="autoComplete1"
TargetControlID="txtSearch"
ServicePath="AutoCompleteWS.asmx"
ServiceMethod="AutoCompleteExplorableObjects"
MinimumPrefixLength="2"
CompletionInterval="1000"
EnableCaching="true"
CompletionSetCount="20"

CompletionListCssClass="autocomplete_completionListElement"

CompletionListItemCssClass="autocomplete_listItem"

CompletionListHighlightedItemCssClass="autocomplete_highlightedListItem"
DelimiterCharacters=";, :">

AutoCompleteWS.asmx:
[WebService(Namespace = "http://tempuri.org/")]
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
[System.Web.Script.Services.ScriptService]
public class AutoCompleteWS : System.Web.Services.WebService
{

[System.Web.Services.WebMethod]
[System.Web.Script.Services.ScriptMethod]
public string[] AutoCompleteExplorableObjects(string prefixText, int
count)
{
return BussinesLogic.AutoCompleteExplorableObjects(prefixText,
count);
}
}

Did anyone have this kind of problem and how can it be solved? Thanks!
 
S

Steph

Stefan said:
Hello,

I have an ajax autocomplete extented on a page and it works just fine in the
ASP .net Development Server, but after I put it on an IIS server it doesn't
work anymore. Here's the code I have:

Start.aspx:
<ajaxToolkit:AutoCompleteExtender
runat="server"
BehaviorID="AutoCompleteEx"
ID="autoComplete1"
TargetControlID="txtSearch"
ServicePath="AutoCompleteWS.asmx"
ServiceMethod="AutoCompleteExplorableObjects"
MinimumPrefixLength="2"
CompletionInterval="1000"
EnableCaching="true"
CompletionSetCount="20"

CompletionListCssClass="autocomplete_completionListElement"

CompletionListItemCssClass="autocomplete_listItem"

CompletionListHighlightedItemCssClass="autocomplete_highlightedListItem"
DelimiterCharacters=";, :">

AutoCompleteWS.asmx:
[WebService(Namespace = "http://tempuri.org/")]
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
[System.Web.Script.Services.ScriptService]
public class AutoCompleteWS : System.Web.Services.WebService
{

[System.Web.Services.WebMethod]
[System.Web.Script.Services.ScriptMethod]
public string[] AutoCompleteExplorableObjects(string prefixText, int
count)
{
return BussinesLogic.AutoCompleteExplorableObjects(prefixText,
count);
}
}

Did anyone have this kind of problem and how can it be solved? Thanks!
test your webservice : http://localhost/myproject/AutoCompleteWS.asmx
or use "firefox" and "firebug" extension for analyse the http request
and response server...
 
Joined
Aug 28, 2012
Messages
1
Reaction score
0
the method that returns a string array of search results should be static:
public static string[] GetCompletionList(string prefixText, int count)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,733
Messages
2,569,440
Members
44,830
Latest member
ZADIva7383

Latest Threads

Top