Until version 6.0 it was possible to set the Grid PageSize to "All" by setting it to the total item count. This workaround no longer works.
Please enhance the API to allow setting an "All" page size with code or initially.
Hi,
documentation missing one extremely "silent" breaking change in grid data binding.
When binding/refreshing(subsequent reload) data to VARIABLE, there is "random" need to call grid.Rebind(); Mostly, when data are loaded outside of the grid, ie by some button, or another component. Used together with selected items and grouping enabled.
<TelerikGrid Data="@GridData" SelectionMode="GridSelectionMode.Single" SelectedItems="..."
OnRowClick="@...r" @ref="GHL" ....>
prior v6.0, everything is OK:
protected async Task ReloadGrid(int? xid)
{
GridData= await LoadDatafromservice<TItem>...;
}
After upgrading same code, it silently not displaying data or cras.
new breaking behavior at v6.0 - hotfix, but "ugly one":
protected async Task ReloadGrid(int? xid)
{
GridData= await LoadDatafromservice<TItem>...;
GHL.Rebind(); //required, otherwise grid content(rows) is not update. Later the grid crash when selecting row etc. Old "rows" are still displayed;
}
Its weird to gues, where rebind is needed and where not. Previous versions acting as expected(async - task = no problem).
Make it documented, "what is correct" and when.
Or if it is a bug, please move it out from feature request.
Thanks
When you combine frozen column with row selection and horizontal scrolling is applied (due to column and grid widths), column content are not hidden under frozen columns when a row is selected, as seen bellow in lines 2,3 and 4.
Checkbox, Product Name & Command columns are frozen. "Quantity per Unit" values are clearly visible behind frozen "Product Name" values. You can find a test scenario here (Telerik REPL for Blazor).
All themes suffer from this issue except Fluent theme. With default and bootstrap themes it happens on all odd selected lines and with material theme it happens on all selected lines.
Could there be an option to NOT close the filter dropdown when the clear button is pressed? Is there an AutoClose parameter or something else?
I just got a request for this, and their thought is they will have a filter set, then want to click clear, and then still pick new items to filter before leaving the dropdown.In this example. Select a cell in column C. Then double click on another cell in column C. The unhandled exception will show up and a null reference exception is logged in the console.
https://blazorrepl.telerik.com/QHuSQBlj170zO4u130
The exception message is:
System.InvalidOperationException: TelerikValidationComponent requires a cascading parameter of type EditContext. You can use Telerik.Blazor.Components.TelerikValidationTooltip`1[System.String] inside a EditForm or TelerikForm.
Hi,
when using SetStateAsync(), OnRead is called ok, but loading indicator is not presented as usual.
How to reproduce:
1. button = loading data by SetStateAsync(), no progress indicated.
2. button = loading data throught rebind, is ok
demo is based on https://docs.telerik.com/blazor-ui/components/grid/refresh-data
Expected: same behavior as by button 2. -> Rebind()->OnRead()...loading progress
Thanks
Error: System.OverflowException: Value was either too large or too small for a Decimal.
Hi,
it seems that grid.GetState() and FilterDescriptors, contains +1 "dummy" object.
- If it is by design, ok, BUT then, how to bind this filter descriptor to the ie TelerikFilter? = It displays that dummy object as it is, and confusing end users. Or how to "identify 100%" that is some kind of dummy value to be trashed?
How to reproduce:
1 run the repl demo
2 put "a" into the first colum(Name) filter
3 click button and observe the content of filter descriptors(serialized below the grid - RED is wrong, Green is expected as ok)
similar, but not the same(iam came from here):
Thanks for the tip, clarification, or removing that redundant values.
Grid headers are misaligned if they are navigated in a scrolling scenario with a Frozen column.
===
ADMIN EDIT
===
The behavior affects the TreeList as well in a similar fashion. The misalignment is bigger when there is a frozen column but it is also reproducible without it in this demo.
On grids with a lot of data there is a delay between when the grid is assigned the data to when the grid shows the data. During this UI painting period, the NoDataTemplate is displayed for a second or two.
The grid should not show the NoDataTemplate unless the data source is loaded with an empty collection, not just while it is still trying to show the data.
Note: Having a generic message like in the documentation "No Data available / The data is still loading ..." is not satisfying our users. (Blazor Grid - No Data Template - Telerik UI for Blazor) These should really be two different states that can show different messages.
Thanks
The value of the FileName parameter is not updated properly in the OnBeforeExport event handler.
When the user drags a third column to the Grid Group Panel, it ends up being second, instead of last. It looks like each new column is inserted at index 1, instead of appended last (when this is the user's intent).
@using Telerik.DataSource
<p>Group by a third column, so that it should come last in the Group Panel:</p>
<TelerikGrid @ref="@GridRef"
Data="@GridData"
Pageable="true"
Sortable="true"
Groupable="true"
FilterMode="GridFilterMode.FilterRow"
OnStateInit="@( (GridStateEventArgs<Employee> args) => OnGridStateInit(args) )"
OnStateChanged="@( (GridStateEventArgs<Employee> args) => OnGridStateChanged(args) )">
<GridColumns>
<GridColumn Field="@nameof(Employee.Name)" />
<GridColumn Field="@nameof(Employee.Team)" />
<GridColumn Field="@nameof(Employee.Salary)" />
<GridColumn Field="@nameof(Employee.OnVacation)" />
</GridColumns>
</TelerikGrid>
@code {
private TelerikGrid<Employee>? GridRef { get; set; }
private List<Employee> GridData { get; set; } = new();
private void OnGridStateInit(GridStateEventArgs<Employee> args)
{
args.GridState.GroupDescriptors = new List<GroupDescriptor>();
args.GridState.GroupDescriptors.Add(new GroupDescriptor()
{
Member = nameof(Employee.Team),
MemberType = typeof(string)
});
args.GridState.GroupDescriptors.Add(new GroupDescriptor()
{
Member = nameof(Employee.OnVacation),
MemberType = typeof(bool)
});
}
private async Task OnGridStateChanged(GridStateEventArgs<Employee> args)
{
if (args.PropertyName == "GroupDescriptors" && args.GridState.GroupDescriptors.Count > 2 && GridRef != null)
{
var secondGroupDescriptor = args.GridState.GroupDescriptors.ElementAt(1);
args.GridState.GroupDescriptors.Remove(secondGroupDescriptor);
args.GridState.GroupDescriptors.Add(secondGroupDescriptor);
await GridRef.SetStateAsync(args.GridState);
}
}
protected override void OnInitialized()
{
var rnd = new Random();
for (int i = 1; i <= 20; i++)
{
GridData.Add(new Employee()
{
Id = i,
Name = "Name " + i,
Team = "Team " + (i % 4 + 1),
Salary = (decimal)rnd.Next(1000, 3000),
OnVacation = i % 3 == 0
});
}
}
public class Employee
{
public int Id { get; set; }
public string Name { get; set; } = string.Empty;
public string Team { get; set; } = string.Empty;
public decimal Salary { get; set; }
public bool OnVacation { get; set; }
}
}
The null type of operator can cause errors on the backend
*** Thread created by admin on customer behalf ***
I would like to be able to edit both Date and Time in Grid editing mode.
===
Telerik edit: Possible since version 3.1.0 with through the column EditorType parameter.