MultiColumnComboBox server filtering issue

0 Answers 22 Views
MultiColumnComboBox
Bart
Top achievements
Rank 1
Bart asked on 27 Oct 2021, 02:38 PM

Hi,

I have the following snippet in my ASP.NET 

<TELERIK:RADMULTICOLUMNCOMBOBOX ID="RadMultiColumnComboBoxSearch" runat="server" Filter="startsWith" FilterFields="DrawingName, Description"
	Height="800" AllowPaging="true" EnableServerFiltering="true" MinLength="3" PageSize="60" DataTextField="DrawingName" DataValueField="DrawingID">
	<COLUMNSCOLLECTION>
		<TELERIK:MULTICOLUMNCOMBOBOXCOLUMN Field="DrawingID" Title="ID" />
		<TELERIK:MULTICOLUMNCOMBOBOXCOLUMN Field="DrawingName" Title="Name" />
		<TELERIK:MULTICOLUMNCOMBOBOXCOLUMN Field="Description" Title="Description" />
	</COLUMNSCOLLECTION>
	<WEBSERVICESETTINGS ServiceType="XML" Select-DataType="JSON" Select-Url="Default.aspx/GetDrawingsSuggestion" Select-RequestType="Post" />
</TELERIK:RADMULTICOLUMNCOMBOBOX>

[WebMethod()]
public static string GetDrawingsSuggestion(string filter)
{
	string filterText = HttpUtility.UrlDecode(filter);

	using (HEN_INTRANET_ProductionEntities dc = new HEN_INTRANET_ProductionEntities())
	{
		var q = from d in dc.tbl_ENECR_Drawings
				where (d.DrawingFlag == 1 | d.DrawingFlag == 2) && d.DrawingTypeID == 1
				select new
				{
					DrawingID = d.DrawingID,
					DrawingName = d.DrawingName,
					Description = d.Description,
				};
		var drawingsList = q.ToList();

		return Newtonsoft.Json.JsonConvert.SerializeObject(drawingsList);
	}
}

Can I use a page method service to get the data I need from the server?
Looking in Fiddler the call to the GetDrawingsSuggestion method occurs, but it returns the page contents. It does not execute the method. It just returns the rendered page.

No answers yet. Maybe you can help?

Tags
MultiColumnComboBox
Asked by
Bart
Top achievements
Rank 1
Share this question
or