Hey guys,
Thanks for this amazing software!
Unfortunately, I am experiencing some trouble using the Blazor DataGrid virtualization. The first scroll is not triggering the LoadData event. My (row height * page size) > grid height.
I've included a video here:
Video of issue
<RadzenDataGrid @ref="grid" Data="@queryFiles" Count="@count" LoadData="@LoadData" TItem="SortedFileVM" AllowVirtualization="true" Style="height:400px;"
AllowFiltering="true" FilterCaseSensitivity="FilterCaseSensitivity.CaseInsensitive" LogicalFilterOperator="LogicalFilterOperator.Or"
AllowSorting="true" CellRender="@CellRender" SelectionMode="DataGridSelectionMode.Single" CellContextMenu="@OnCellContextMenu" AllowColumnResize="true">
<Columns>
<RadzenDataGridColumn TItem="SortedFileVM" Property="GalleryName" Title="Gallery name" />
<RadzenDataGridColumn TItem="SortedFileVM" Property="CameraName" Title="Camera" Width="140px" />
<RadzenDataGridColumn TItem="SortedFileVM" Title="Photo" Frozen="false" Sortable="false" Filterable="false" Width="120px">
<Template Context="detail">
<RadzenImage Path="@detail.Thumb" />
<div class="fileName">@Path.GetFileName(detail.FilePath)</div>
</Template>
</RadzenDataGridColumn>
<RadzenDataGridColumn TItem="SortedFileVM" Property="StartTime" Title="Log time" Width="140px">
<Template Context="detail">
@String.Format("{0:ddd, MMM dd, yyyy}", detail.StartTime)
<br />
@String.Format("{0}", detail.StartTime.ToLongTimeString())
</Template>
</RadzenDataGridColumn>
<RadzenDataGridColumn TItem="SortedFileVM" Property="FileCreatedDate" Title="File created" Filterable="false" Width="140px">
<Template Context="detail">
@String.Format("{0:ddd, MMM dd, yyyy}", detail.FileCreatedDate)
<br />
@String.Format("{0}", detail.FileCreatedDate.ToLongTimeString())
<br />
@*@{ TimeSpan duration = detail.FileCreatedDate - detail.StartTime;}
@String.Format("{0} minutes after SortMagic log", duration.TotalMinutes)*@
</Template>
</RadzenDataGridColumn>
</Columns>
</RadzenDataGrid>
void CellRender(DataGridCellRenderEventArgs<SortedFileVM> args)
{
args.Attributes.Add("style", "overflow: visible; whitespace: auto; height:166px;");
}