When I try to set the Skin to Material I obtain the following Error:
WebResource.axd?d=e4b2sCc8Q8M6A2MgSsDltOpyL908K1Q7T29bPdSz7Supj8wwNwBiCRISuCJlWYcTaJsmG21ZOfynS4jGurXXbpli-ERqUAuqN0-JIBovYD49aTvhGO3Rn_RCmsSdUlmwuseC48k3n557KQEGgkr2hCHOsY41&t=638423073240000000] DETAILS: System.Web Exception: msg:Richiesta webresource non valida.
The problem happens when the ButtonType="ImageButton" is set with the Material skin:
<telerik:GridEditCommandColumn ButtonType="ImageButton" HeaderStyle-Width="20px" >
</telerik:GridEditCommandColumn>
<telerik:GridButtonColumn ButtonType="ImageButton" UniqueName="DeleteColumn" Text="Elimina" HeaderStyle-Width="20px" CommandName="Delete" ConfirmText="Procedere con la cancellazione del Cimitero?"></telerik:GridButtonColumn>
Found an additional issue when implementing this on a project:
When aria-enabled=true and we follow their instructions if we have a gridnumericcolumn in the grid, then we get a finding that "Elements must only use supported ARIA attributes" because To solve this problem, you need to fix the following:
ASPX
<telerik:RadGrid ID="RadGrid1" runat="server" AutoGenerateColumns="False" AllowFilteringByColumn="true" OnNeedDataSource="RadGrid1_NeedDataSource" EnableAriaSupport="true">
<ClientSettings>
<ClientEvents OnGridCreated="OnGridCreated" />
</ClientSettings>
<MasterTableView>
<Columns>
<telerik:GridBoundColumn DataField="ID" HeaderText="ID" UniqueName="ID" />
<telerik:GridBoundColumn DataField="Name" HeaderText="Name" UniqueName="Name" />
<telerik:GridCheckBoxColumn DataField="IsActive" HeaderText="Active" UniqueName="IsActive" />
<telerik:GridNumericColumn DataField="Score" HeaderText="Score" UniqueName="Score" DataType="System.Int32" DataFormatString="{0:N0}" />
</Columns>
</MasterTableView>
</telerik:RadGrid>
ASPX.CS
protected void RadGrid1_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
{
// Creating a dummy data source
var data = new List<DummyData>
{
new DummyData { ID = 1, Name = "John Doe", IsActive = true, Score = 88 },
new DummyData { ID = 2, Name = "Jane Doe", IsActive = false, Score = 92 }
};
RadGrid1.DataSource = data;
}
public class DummyData
{
public int ID { get; set; }
public string Name { get; set; }
public bool IsActive { get; set; }
public int Score { get; set; }
}
When the AriaSupport for the Grid is turned on, an aria-label is added to each column header automatically using the UniqueName of the column. The problem is - UniqueName doesn't support empty spaces - all "labels" must be single words or use Underscores - and the screen readers say "underscore."
So my column of "call_date" results in "Call underscore Date" - which is not useful for visually impaired people.
Hi,
How can I translate the "clear" button in the mobile Filter Window? I manage to translate everything in that window except the clear button:
King regards
Blas González
Hi,
Heres a simple one: I have a dynamic grid `MasterTableView.EnableColumnsViewState = false;` on page init and all works fine. However, when the client/browser show a dynamic column thats hidden (or vise versa), and the column is gone on postback (being a dynamic grid this can happen), the LoadClientState tries to get the column - and if it fails to, it breaks down hard.. Instead it should just ignore it, as its just a pretty un-important show/hide state.
Your RadGrid code goes something like this:
LoadClientState ->
if (clientState.ContainsKey("showedColumns")) ->
control.GetColumn(columnUniqueName).Display = true; <-- just ignore this if not found - also on the others like hide, resize etc.
Thank you!... +1 for making this html editor a MD flavor instead :)
/Anders
HeaderContextMenu filter functions such as "GreaterThanOrEqualTo", "LessThanOrEqualTo" are not working.
This issue happens with the Header Context Menu. The following scenarios are affected:
When the Grid is set to have FilterType="HeaderContext" and filtering by a keyword that starts with a question mark "?MyKeyword", an exception will be thrown: System.ArgumentOutOfRangeException: Index was out of range.
The issue can be replicated in our online demo Excel-like Filtering.
Note that the demos will not display the exact exception because it is handled by the CustomError mechanism of the demo site.
<script runat="server">
protected void RadGrid1_NeedDataSource(object sender, Telerik.Web.UI.GridNeedDataSourceEventArgs e)
{
(sender as RadGrid).DataSource = Enumerable.Range(1, 10).Select(x => new { Id = x, Name = "Name " + x });
}
</script>
<telerik:RadFormDecorator ID="RadFormDecorator1" runat="server" DecorationZoneID="test" DecoratedControls="All" />
<div id="test">
<telerik:RadGrid ID="RadGrid1" runat="server" OnNeedDataSource="RadGrid1_NeedDataSource" AutoGenerateColumns="true"
EnableHeaderContextMenu="true" FilterType="HeaderContext">
</telerik:RadGrid>
</div>
By changing the application's thread Culture to Persian (fa-IR) and the Grid's RenderMode to Lightweight, the application fails with "System.ArgumentOutOfRangeException: Specified argument was out of the range of valid values."
1. Change the application culture to Persian
protected void Page_Init(object sender, System.EventArgs e)
{
var culture = new System.Globalization.CultureInfo("fa-IR");
System.Threading.Thread.CurrentThread.CurrentCulture = culture;
System.Threading.Thread.CurrentThread.CurrentUICulture = culture;
}
2. Change the RenderMode of the Grid to Lightweight
<telerik:RadGrid ID="RadGrid1" runat="server" RenderMode="Lightweight">
</telerik:RadGrid>
Current RadGrid only has headers/header templates for column headers. The only way to have headers for each row would be to manipulate the grid data and adding the header for each row into the grid data itself. And if we wanted to group the row headers is another round of manipulating the grid data and also manually merging the cells. Is it possible to have to have it as a feature of the RadGrid just like column groups and column headers to simplify the task? example of the final output ->
Replicated when the ClickToOpen is enabled:
protected void Page_Load(object sender, EventArgs e)
{
RadGrid1.HeaderContextMenu.ClickToOpen = true;
}
WORKAROUND: Loading the following script under the script manager
<script>
var original = Telerik.Web.UI.GridColumn.prototype._onContextMenuItemClicking;
Telerik.Web.UI.GridColumn.prototype._onContextMenuItemClicking = function (sender, args) {
original.call(this, sender, args);
var item = args.get_item();
var itemValue = item.get_value();
if (itemValue == "FilterList" || itemValue == "FilterMenuContainer" ||
itemValue == "AggregatesContainer" || itemValue == "FilterMenuParent" || itemValue == "ColumnsContainer" ||
(Telerik.Web.UI.RadMenuItem.isInstanceOfType(item.get_parent()) && item.get_parent().get_value() == "ColumnsContainer")) {
if (sender.get_clickToOpen()) {
args.get_item().open();
}
}
}
</script>
I issue is replicated consistently with the following simple setup, when the page is scrolled so the grid is on the top and right-clicking the column, to open the menu
<div style="height: 200px"></div>
<telerik:RadGrid ID="RadGrid2" runat="server" AllowFilteringByColumn="true" EnableHeaderContextMenu="true">
</telerik:RadGrid>
<script runat="server">
protected void Page_Load(object sender, EventArgs e)
{
RadGrid2.DataSource = Enumerable.Range(1, 3).Select(x => new { ID = 1, Desc = "Some text" });
RadGrid2.DataBind();
}
</script>
<div style="height: 4000px"></div>
Hi,
Without using radFilter to setup multiple filters before applying RadGrid can only be filtered one column at a time. Can a button be added to the Grid when filtering is applied that when Clicked will filter the Grid based on all of the column filter selections that a user selects?
Thanks,
When page scrolling is enabled and scrolling down the page, the row context menu of RadGrid rows do not open at a correct position.
Demo: Video Recording
Testing conducted in Safari 13, MacOS
I would assume that Delete and Edit columns should never be exported to excel to begin with, especially if HideStructureColumns="true".
If the HideStructureColumns is hiding something else, it would be nice to have another flag that would control showing/hiding Edit/Delete columns.
Hello,
There is an issue with Classic render mode Grid when grouping is enabled. The width of the grouping is incorrect and some of the icons are wrapped on the next row.
I found issue here in your forum and received an updated fix.
However, the sample fix has the grid name ("RadGrid1") hard-coded in the method "function OnClientHidden(sender, args)". In our code we need to use this for many grids; each with its own name. Please show me how to obtain the grid name generically; preferably from the arguments (sender, args).
Also in the example the checkbox isn't explicitly declared; I assume the code is using some implicit name. However, in our code the name of the checkbox is declared (see below my signature). Please show me how to change the code to use different checkbox names.