or
My situation
I have a RadGrid where some columns contain RadComboBoxes. These RadComboBoxes only display a code (mostly 3 characters), when they open they display two columns (the code and a description).
My RadComboBox is defined as follows:
| <telerik:RadComboBox Width="65px" DropDownWidth="270" ID="radComboBoxVHT" |
| Filter="contains" AllowCustomText="true" HighlightTemplatedItems="true" |
| markfirstmatch="true" runat="server" EnableLoadOnDemand="true" |
| EnableScreenBoundaryDetection="true" DataSourceID="dataSourceVHT" DataTextField="Code" |
| DataValueField="Code" SelectedValue='<%#Bind("VHTCode") %>' > |
| <HeaderTemplate> |
| <table style="width:250px;" cellspacing="0" cellpadding="0"> <tr> |
| <td style="width:50px;">Code</td> |
| <td style="width:200px;">Description</td> |
| </tr> </table> |
| </HeaderTemplate> |
| <ItemTemplate> |
| <table style="width:250px;" class="comboTable" cellspacing="0" cellpadding="0"> |
| <tr> |
| <td style="width:50px;"> |
| <div class='comboItem'> |
| <%#DataBinder.Eval(Container.DataItem, "Code")%> |
| </div> |
| </td> |
| <td style="width:200px;"> |
| <div class='comboItem'> |
| <%#DataBinder.Eval(Container.DataItem, "Description")%> |
| </div> |
| </td> |
| </tr> |
| </table> |
| </ItemTemplate> |
| </telerik:RadComboBox> |
The problem
When the user starts typing in the combobox, it's only filtering on the first column (Code). I also wants it to filter on the second column. In fact: on both columns.
Example I have following two items in the combobox:
REQ | Send a request
FIN | Require finishing
When the user starts typing "req" I still want to see both items, and not only the first.
[Serializable] public class ExtendedAsyncUploadResult : IAsyncUploadResult { public string TempFileName { get; set; } public bool Valid { get; set; } public string ValidationMessage { get; set; } public int ContentLength { get; set; } public string ContentType { get; set; } public string FileName { get; set; } public int Pages { get; set; } public ExtendedAsyncUploadResult() { this.TempFileName = string.Empty; this.ValidationMessage = string.Empty; this.ContentType = string.Empty; this.FileName = string.Empty; } } public class ExtendedAsyncUploadHandler : Telerik.Web.UI.AsyncUploadHandler { protected override IAsyncUploadResult Process(UploadedFile file, HttpContext context, IAsyncUploadConfiguration configuration, string tempFileName) { IAsyncUploadResult result = base.Process(file, context, configuration, tempFileName); ExtendedAsyncUploadResult extendedResult = base.CreateDefaultUploadResult<ExtendedAsyncUploadResult>(file); extendedResult.TempFileName = tempFileName; try { string imagePath = Path.Combine(configuration.TempTargetFolder, tempFileName); if (File.Exists(imagePath)) { ImagingService.ImagingServiceClient client = new ImagingService.ImagingServiceClient("NetTcpBinding_IImagingService"); ImageServiceValidationResult validationResult = client.ValidateImage( imagePath, Path.GetExtension(result.FileName)); extendedResult.Valid = validationResult.State == ImageServiceValidationResult.ValidState.Valid; extendedResult.ValidationMessage = validationResult.Errors.ToString(); extendedResult.Pages = validationResult.PageCount; } else { throw new Exception("File does not exist."); } } catch (Exception ex) { extendedResult.ValidationMessage = ex.Message; extendedResult.Valid = false; } return extendedResult; } }