Hi. I'm using Telerik 2016.3.1027.40. I need to export an Excel spreadsheet in BIFF that includes both the data that appears in a UI table, which Telerik handles, and any table filtering criteria and the filtering option (Contains, StartsWith, EqualTo, Between, etc.) on an additional tab on the worksheet. I can create the additional tab and population it with data. My question is: is it possible to retrieve the filtering option used per column (if any) in the UI in the view's code behind?
<telerik:Radgrid Rendermode="Lightweight" ID="RadGrid1" runat="server" showstatusbar="true" autogeneratecolumns="False" AllowFilteringByColumn="True" pagesize="10" allowsorting="True" allowmultirowselection="False" allowpaging="True" Filtertype="Combined" onneeddatasource="RadGrid1_NeedDataSource" oniteminserted="RadGrid1_ItemInserted" onitemcommand="RadGrid1_ItemCommand" oninsertcommand="RadGrid1_InsertCommand" onupdatecommand="RadGrid1_UpdateCommand" onitemdatabound="RadGrid1_ItemDataBound" ondetailtabledatabind="RadGrid1_DetailTableDataBind" OnDeleteCommand="RadGrid1_DeleteCommand" Skin="Outlook" OnItemCreated="RadGrid1_ItemCreated" ShowExportToExcelButton="true" onBiffExporting="RadGrid1_BiffExporting"> <MasterTableView AutoGenerateColumns="False" UniqueName="CATDESCRIPTION" AllowMultiColumnSorting="True" DataKeyNames="CAT_DESCRIPTION" PagerStyle-AlwaysVisible="true" EditMode="InPlace" CommandItemDisplay="Top"><DetailTables> <telerik:GridTableView DataKeyNames="pk" Name="Codes" TableLayout="Auto" EditMode="InPlace" PagerStyle-AlwaysVisible="true" CommandItemDisplay="Top"> <CommandItemSettings ShowExportToExcelButton="true" /> <CommandItemSettings AddNewRecordText="Add Rule" />Additional code omitted...
and the code behind something like this...
protected void RadGrid1_BiffExporting(object o, GridBiffExportingEventArgs e) { Telerik.Web.UI.ExportInfrastructure.Table newSheet1 = new Telerik.Web.UI.ExportInfrastructure.Table("Metadata"); // Get filtering options here... // Add filtering options to newSheet1 in new cells...
e.ExportStructure.Tables.Add(newSheet1);}
I am attempting to use the below to apply a css class to rows in my rad grid. I am only showing a brief portion of the code behind as I only need to apply this to a few of the rows.
However, the css is not applied. What would be the proper way to achieve such?
foreach (GridDataItem row in r.MasterTableView.Items)
{
row.CssClass = "blamanca";
}

Hi
I have a need to test the column name. Is it possible in the itemDatabound event to get to the actual column name that is being bound to?
I'd expect this to change with each cell, or does the bind happen per row in one go?
Andy
I'd like to give the user a popup or tooltip of some sort that lets them know that, yes a search has been conducted with the text they've provided but there are no results with their input.
Unfortunately all the events I've tried are too early (the data source's OnSelected) or don't get triggered (the search box's Search). How can I achieve this?
Hi,
I have a RadWindowManager on a page where I have a function assigned to the OnClientBeforeClose event.
<telerik:RadWindowManager ID="rwmManager" runat="server" DestroyOnClose="true" ReloadOnShow="true" CenterIfModal="true" OnClientClose="RefreshGrid" OnClientBeforeClose="ChangeAlert" />
The problem I am having is that the OnClientBeforeClose event only fires the first time I open the window. If I close the window and then re-open and then subsequently close the window, the OnClientBeforeClose event doesn't fire.
If I change the DestroyOnClose = "false" then the event will fire every time, but the previous window I opened gets cached and flashes on the screen before the new window is opened.
How can I make this work without setting the DestroyOnClose to false.
Thank You
Tracy
'm using Telerik UI for ASP.NET AJAX R1 2018. When I use the AntiXssEncoder as the default encoder... <httpRuntime encoderType="Microsoft.Security.Application.AntiXssEncoder, AntiXssLibrary" maxRequestLength="102400"/>I have a RadDropDownList in a TemplateColumn of a RadGrid. The grid is using batch editing mode, and the drop-down list is loading its data from a web service.
This is all generally working, except for the fact that the DDL does not load it's items until the first time you click on the control. Unfortunately, that is a tad too late for the existing value to be retained the first time that it is used. Editing subsequent rows is fine.
So, I'd like to cause the DDL to load it's items earlier. Is there a way to trigger the RadDropDownList to dynamically load it's list on demand??