I have the following RadSearchBox declaration in my default.aspx page:
<div style="margin-right: 1px; margin-top: 1px;">
<telerik:RadSearchBox runat="server" ID="rsbOrgSearch"
DataKeyNames="BUHierarchyId"
DataValueField="BUHierarchyId"
DataTextField="BU_Name"
EnableAutoComplete="true"
ValidateRequestMode="Disabled"
Width="340"
OnSearch="rsbOrgSearch_Search" ShowSearchButton="false" EmptyMessage="Search For BU" Filter="Contains">
<DropDownSettings Width="340" />
</telerik:RadSearchBox>
</div>
The datasouce for the searchbox is set in the Page_Load code behind. However, when I type in the searchbox the autocomplete doesn't work. It does not respond at all.
I'm developing this in Visual Studio 2015, using C#, targeting framework 4.6.1, with the UI for ASP.NET AJAX Q1 2015 version of Telerik controls.
Thanks for your help.
Manuel Avendaño.
9 Answers, 1 is accepted
I do not reproduce such an issue on my side with the setup provided. It would be helpful if you share the codebehind used as well. As a side note, the DataKeyNames property is used for additional fields - demo. You are setting one and the same field for DataKeyNames and DataValueField.
Regards,
Dimitar
Telerik by Progress

I found out that the issue is related to the fact that the web server (bot the IIS Express from Visual Studio and IIS 7) is hiding the .aspx extention from Default.aspx so the control seem to interpret /apps/CRDB/Default as a directory instead of an aspx page. I've attached a fiddler trace for better understanding.
The search bar in the IE browser looks like http://server/apps/crdb/Default when it should look like http://server/apps/crdb/Default.aspx
So it looks like the radsearchbox is confused by not finding a "Default" subfolder.
Every 500 error you see in the trace is when I press a key in the keyboard on the radsearchbox.
Please let me know if you know how to fix this issue.
Thank you;
Manuel.

Do we need to do anything to the RegisterRoutes() and RegisterBundles() methods in Global.asax.cs for the Telerik controls at all?
Manuel.
I would suggest you to exclude the Telerik.Web.UI.WebResource.axd from URL rewriting, as suggested in the following forum thread. If this approach does not resolve the issue, it would be helpful if you provide an isolated runnable sample project, which could be used to replicate the issue on our side.
Regards,
Dimitar
Telerik by Progress

It seems that the issue is caused by having a RadSearchBox and a RadWindowManager at the same time. I'm attaching a simplified sample code for your review.
Thank you for the help in this case.
Manuel.
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SearchTest.aspx.cs" Inherits="CaRDS.WEB.SearchTest" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<telerik:RadScriptManager ID="RadScriptManager1" runat="server"></telerik:RadScriptManager>
<div>
<telerik:RadSearchBox ID="RadSearchBox1" runat="server"
DataValueField="IdColumn"
DataTextField="NameColumn"
EnableAutoComplete="true"
ValidateRequestMode="Disabled"
ShowSearchButton="false"
EmptyMessage="Type a number"
Filter="Contains"></telerik:RadSearchBox>
</div>
<div>
<telerik:RadWindowManager ID="radWindowManager1" runat="server">
<Windows>
</Windows>
</telerik:RadWindowManager>
</div>
</form>
</body>
</html>
Code behind:
public partial class SearchTest : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
RadSearchBox1.DataSource = LoadData();
RadSearchBox1.DataBind();
}
private DataTable LoadData()
{
DataTable newTable = new DataTable();
DataColumn idColumn = new DataColumn("IdColumn");
DataColumn nameColumn = new DataColumn("NameColumn");
newTable.Columns.Add(idColumn);
newTable.Columns.Add(nameColumn);
DataRow row = newTable.NewRow();
row["IdColumn"] = 1;
row["NameColumn"] = "One";
newTable.Rows.Add(row);
row = newTable.NewRow();
row["IdColumn"] = 2;
row["NameColumn"] = "Two";
newTable.Rows.Add(row);
row = newTable.NewRow();
row["IdColumn"] = 3;
row["NameColumn"] = "Three";
newTable.Rows.Add(row);
row = newTable.NewRow();
row["IdColumn"] = 4;
row["NameColumn"] = "Four";
newTable.Rows.Add(row);
row = newTable.NewRow();
row["IdColumn"] = 5;
row["NameColumn"] = "Five";
newTable.Rows.Add(row);
row = newTable.NewRow();
row["IdColumn"] = 6;
row["NameColumn"] = "Six";
newTable.Rows.Add(row);
return newTable;
}
}
The issue is not reproducible on my side with the sample code provided - video. It is most probably related to URL rewriting. Did you follow the recommendations of the forum post from my previous reply? It would be helpful if you provide a sample, including an isolated web.config used.
Regards,
Dimitar
Telerik by Progress

Thank you Dimitar for looking into this.
I did try removing the WebResource.axd handler from the rewrite but that didn't work (maybe I didn't do it right?)
However, as soon as I remove the RadWindowManager the autocomplete works, if I put it again, it stops working.
I tried attaching a zip file with my sample solution, however it seems I can only attach image files. Is there an email account I can send the zip to? In any case, I'm pasting my web.config code below.
Please remember that I'm using Visual Studio 2015 and the telerik controls version: UI for ASP.NET AJAX Q1 2015.
Thank you;
Manuel.
<?xml version="1.0"?>
<!--
For more information on how to configure your ASP.NET application, please visit
http://go.microsoft.com/fwlink/?LinkId=301880
-->
<configuration>
<appSettings>
<add key="ida:ADFSMetadata" value="https://sts-dev.fiservcorp.net/FederationMetadata/2007-06/FederationMetadata.xml"/>
<add key="ida:Wtrealm" value="https://localhost:44384/"/>
</appSettings>
<location path="Account">
<system.web>
<authorization>
<allow users="*"/>
</authorization>
</system.web>
</location>
<system.web>
<authorization>
<!--<deny users="?"/>-->
</authorization>
<compilation debug="true" targetFramework="4.5.2">
<assemblies>
<add assembly="System.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
<add assembly="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
<add assembly="System.Management, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
<add assembly="PresentationCore, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add assembly="System.Speech, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
</assemblies>
</compilation>
<httpRuntime targetFramework="4.5.2"/>
<pages>
<namespaces>
<add namespace="System.Web.Optimization"/>
</namespaces>
<controls>
<add assembly="Microsoft.AspNet.Web.Optimization.WebForms" namespace="Microsoft.AspNet.Web.Optimization.WebForms" tagPrefix="webopt"/>
</controls>
</pages>
</system.web>
<system.webServer>
<modules>
<remove name="FormsAuthentication"/>
</modules>
</system.webServer>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" culture="neutral" publicKeyToken="30ad4fe6b2a6aeed"/>
<bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="WebGrease" culture="neutral" publicKeyToken="31bf3856ad364e35"/>
<bindingRedirect oldVersion="0.0.0.0-1.5.2.14234" newVersion="1.5.2.14234"/>
</dependentAssembly>
</assemblyBinding>
</runtime>
<system.codedom>
<compilers>
<compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:6 /nowarn:1659;1699;1701"/>
<compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.VBCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:14 /nowarn:41008 /define:_MYTYPE=\"Web\" /optionInfer+"/>
</compilers>
</system.codedom>
</configuration>
I tested your page setup with the web.config provided, but the issue is not reproducible. I tested with your version 2015.1.225. This web.config, however, does not have a handler for web resources, so the page cannot run with it without modifications:
<
handlers
>
<
add
name
=
"Telerik.Web.UI.WebResource.axd_*"
path
=
"Telerik.Web.UI.WebResource.axd"
verb
=
"*"
type
=
"Telerik.Web.UI.WebResource, Telerik.Web.UI"
preCondition
=
"integratedMode"
/>
</
handlers
>
Are you sure it is the correct web.config to be used for issue reproduction? I would suggest you to create an isolated website with the page, code-behind and web.config file and upload it to dropbox. Then provide the URL to download the project and test it on my side.
Regards,
Dimitar
Telerik by Progress
This issue was resolved in a support ticket with the information and workaround from the following KB article:http://www.telerik.com/support/kb/aspnet-ajax/window/details/500-server-error-with-microsoft-owin-and-radwindowmanager-during-a-callback.
--Marin Bratanov