I have a TelerikGrid that I want to export to Excel or CSV, but before I export it I want to add a column. I add the column and set it's Field & Title, which when exported the Field data is shown but not the Title.
I have followed the documentation and created a hidden column, then using the OnBeforeExport event, added the column to the list but still the Title does not export.
Am I missing something?
Hi
Is it possible to hide these buttons?
Eric
Hi, I have a problem with first login page in Blazor NET 6, because there was changed _layout and _host pages.
In Core 3.1. it works https://www.youtube.com/watch?v=PgDEpkWbsew, but I don't know how can I do it in Net 6
Can you help me, please.
Thanks
Peter
Why this happening after selecting the start date?
I have created custom row filtering.
TelerikDateRangePicker is used inside FilterCellTemplate.
Based on the examples from the article -> https://demos.telerik.com/blazor-ui/grid/custom-filter-row <- select start, end dates and clear button handlers was implemented.
But I found that for each handler (select start or end date) new instance of FilterCellTemplateContext has been used.
And when I try to get selected values in OnRead method from GridReadEventArgs -> Request.Filters, filters do not contain selected date range.
Could someone please explain why there are a lot of instances of FilterCellTemplateContext (more that one on each method call)?
How can I get selected date range values in OnRead methods from GridReadEventArgs?
Thanks!
Hello,
the Edit/Preview box on the Blazor documentation is nice. Allows me to quickly try what the specific component or option does and allows. But, if I'm not mistaken, it does not display compilation errors anywhere and this makes the experience in case of an error really bad.
For example, if I go to the Blazor MultiSelect page and edit the first editor available under the "Creating MultiSelect" header. If I make no mistakes, pressing the Preview button compiles the code cleanly and starts the Blazor component with my edits. But, if I make a mistake, let's say near the bottom of the Edit box I accidentally add an extra d to Add like so "Countries.Addd("Albania");", then after pressing the Preview button a couple of things might happen(?)
So please add some kind of a popup with atleast an error saying "Hey, there's some problem with your code, we couldn't compile it, please take another look", or better yet, the actual error and line number if possible.
I've got a TelerikGrid that occasionally loads a very large amount of data and when this happens it will freeze the entire webpage. I was wondering if there is a way to load the grid asynchronously, to allow users to still be able to click other things, or if there is a way to indicate to the user that a loading is occurring. Below is the code for my TelerikGrid and even though I have the line `EnableLoaderContainer="@ShowLoading"` it does not indicate that the grid is loading.
<TelerikGrid
Data="@model.DegradeTableRows"
@ref="@Grid"
Width="100%"
Height="100%"
EnableLoaderContainer="@ShowLoading"
Groupable="true"
Pageable="false"
Sortable="true"
FilterMode="@GridFilterMode.FilterMenu">
<GridColumns>
<GridColumn Field="unitNumb" Width="110px" FieldType="@typeof(int)" Title="Unit Number"/>
<GridColumn Field="grade" Width="100px" Title="Grade" FieldType="@typeof(string)" />
<GridColumn Field="length" Width="100px" FieldType="@typeof(string)" Title="Length"/>
@if (SizeColumnNames is not null && SizeColumnNames.Any())
{
foreach (var sizeColumnName in SizeColumnNames)
{
<GridColumn Width="100px" Field="@sizeColumnName" FieldType="@typeof(int)" Title="@sizeColumnName"/>
}
}
<GridColumn Width="150px" Field="GrandTotal" FieldType="@typeof(decimal)" Title="Grand Total"/>
</GridColumns>
</TelerikGrid>
Telerik Blazor version: 3.4.0, 3.5.0
I'm currently encountering a bug within Telerik Blazor with the TabStrip component. If the first Tab of the TabStrip's visibility is set to false, the component throws an exception:
ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index')
With some debugging, I found what went wrong within Telerik's code. But first, the scenario:
Setup
Create a TelerikTabStrip with three TabStripTab components inside: A, B, C.
Scenario A
Tab A: Visible = false
Tab B: Visible = true
Tab C: Visible = true
Scenario B
Tab A: Visible = true
Tab B: Visible = false
Tab C: Visible = true
Result
Scenario B works fine. Scenario A does not. Why? Basically, it looks like this happens:
Tab => SetParameters() => VisibleChanged = true (because that parameter is set) => TabStrip.OnTabVisibiltyChanged => IsTabActive = true (because it's the first tab) => FindFocusable => this method has only one tab in the list (the first tab) and not the other two tabs because it's still early in the component lifecycle => FindIndex can't find a tab that is visible and not disabled => returns index -1 => this is out of range and throws an exception
Why scenario B works:
Tab A => SetParameters() => VisibleChanged = false (because the parameter is not changed to the default) => basically done
Tab B => SetParameters() => VisibleChanged = true (because we changed that) => TabStrip.OnTabVisibilityChanged => IsTabActive = false (not the first tab, so not active) => basically done
@page "/TabStripTest"
<PageTitle>Telerik tabs error</PageTitle>
<TelerikTabStrip @ref="_stripRef">
<TabStripTab Title="A" Visible="true">
Tab A
</TabStripTab>
<TabStripTab Title="B" Visible="false">
Tab B
</TabStripTab>
<TabStripTab Title="C" Visible="true">
Tab C
</TabStripTab>
</TelerikTabStrip>
@code {
private TelerikTabStrip _stripRef;
}
Full stacktrace:
System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index')
at Telerik.Blazor.Components.TelerikTabStrip.FocusActiveTab()
at Telerik.Blazor.Components.TelerikTabStrip.set_CurrentActiveTabIndex(Int32 value)
at Telerik.Blazor.Components.TelerikTabStrip.Telerik.Blazor.Components.TabStrip.ITabContainer.OnTabVisibleChanged(ITab tab)
at Telerik.Blazor.Components.TabStripTab.OnParametersSetAsync()
at Microsoft.AspNetCore.Components.ComponentBase.CallOnParametersSetAsync()
at Microsoft.AspNetCore.Components.ComponentBase.RunInitAndSetParametersAsync()
at Microsoft.AspNetCore.Components.Rendering.HtmlRenderer.HandleException(Exception exception)
at Microsoft.AspNetCore.Components.RenderTree.Renderer.HandleExceptionViaErrorBoundary(Exception error, ComponentState errorSourceOrNull)
at Microsoft.AspNetCore.Components.RenderTree.Renderer.AddToPendingTasks(Task task, ComponentState owningComponentState)
at Microsoft.AspNetCore.Components.Rendering.ComponentState.SupplyCombinedParameters(ParameterView directAndCascadingParameters)
at Microsoft.AspNetCore.Components.Rendering.ComponentState.SetDirectParameters(ParameterView parameters)
at Microsoft.AspNetCore.Components.RenderTree.RenderTreeDiffBuilder.InitializeNewComponentFrame(DiffContext& diffContext, Int32 frameIndex)
at Microsoft.AspNetCore.Components.RenderTree.RenderTreeDiffBuilder.InitializeNewSubtree(DiffContext& diffContext, Int32 frameIndex)
at Microsoft.AspNetCore.Components.RenderTree.RenderTreeDiffBuilder.InsertNewFrame(DiffContext& diffContext, Int32 newFrameIndex)
at Microsoft.AspNetCore.Components.RenderTree.RenderTreeDiffBuilder.InsertNewFrame(DiffContext& diffContext, Int32 newFrameIndex)
at Microsoft.AspNetCore.Components.RenderTree.RenderTreeDiffBuilder.AppendDiffEntriesForRange(DiffContext& diffContext, Int32 oldStartIndex, Int32 oldEndIndexExcl, Int32 newStartIndex, Int32 newEndIndexExcl)
at Microsoft.AspNetCore.Components.RenderTree.RenderTreeDiffBuilder.ComputeDiff(Renderer renderer, RenderBatchBuilder batchBuilder, Int32 componentId, ArrayRange`1 oldTree, ArrayRange`1 newTree)
at Microsoft.AspNetCore.Components.Rendering.ComponentState.RenderIntoBatch(RenderBatchBuilder batchBuilder, RenderFragment renderFragment, Exception& renderFragmentException)
at Microsoft.AspNetCore.Components.RenderTree.Renderer.ProcessRenderQueue()
--- End of stack trace from previous location ---
at Microsoft.AspNetCore.Components.Rendering.HtmlRenderer.HandleException(Exception exception)
at Microsoft.AspNetCore.Components.RenderTree.Renderer.ProcessRenderQueue()
at Microsoft.AspNetCore.Components.RenderTree.Renderer.ProcessPendingRender()
at Microsoft.AspNetCore.Components.RenderTree.Renderer.AddToRenderQueue(Int32 componentId, RenderFragment renderFragment)
at Microsoft.AspNetCore.Components.ComponentBase.StateHasChanged()
at Microsoft.AspNetCore.Components.ComponentBase.CallOnParametersSetAsync()
at Microsoft.AspNetCore.Components.ComponentBase.RunInitAndSetParametersAsync()
at Microsoft.AspNetCore.Components.Rendering.HtmlRenderer.HandleException(Exception exception)
at Microsoft.AspNetCore.Components.RenderTree.Renderer.HandleExceptionViaErrorBoundary(Exception error, ComponentState errorSourceOrNull)
at Microsoft.AspNetCore.Components.RenderTree.Renderer.AddToPendingTasks(Task task, ComponentState owningComponentState)
at Microsoft.AspNetCore.Components.Rendering.ComponentState.SupplyCombinedParameters(ParameterView directAndCascadingParameters)
at Microsoft.AspNetCore.Components.Rendering.ComponentState.SetDirectParameters(ParameterView parameters)
at Microsoft.AspNetCore.Components.RenderTree.Renderer.RenderRootComponentAsync(Int32 componentId, ParameterView initialParameters)
at Microsoft.AspNetCore.Components.Rendering.HtmlRenderer.CreateInitialRenderAsync(Type componentType, ParameterView initialParameters)
at Microsoft.AspNetCore.Components.Rendering.HtmlRenderer.RenderComponentAsync(Type componentType, ParameterView initialParameters)
at Microsoft.AspNetCore.Components.Rendering.RendererSynchronizationContext.<>c__11`1.<<InvokeAsync>b__11_0>d.MoveNext()
--- End of stack trace from previous location ---
at Microsoft.AspNetCore.Mvc.ViewFeatures.StaticComponentRenderer.PrerenderComponentAsync(ParameterView parameters, HttpContext httpContext, Type componentType)
at Microsoft.AspNetCore.Mvc.ViewFeatures.ComponentRenderer.PrerenderedServerComponentAsync(HttpContext context, ServerComponentInvocationSequence invocationId, Type type, ParameterView parametersCollection)
at Microsoft.AspNetCore.Mvc.ViewFeatures.ComponentRenderer.RenderComponentAsync(ViewContext viewContext, Type componentType, RenderMode renderMode, Object parameters)
at Microsoft.AspNetCore.Mvc.TagHelpers.ComponentTagHelper.ProcessAsync(TagHelperContext context, TagHelperOutput output)
at Microsoft.AspNetCore.Razor.Runtime.TagHelpers.TagHelperRunner.<RunAsync>g__Awaited|0_0(Task task, TagHelperExecutionContext executionContext, Int32 i, Int32 count)
at TelerikTabStripBug.Pages.Pages__Host.ExecuteAsync() in C:\Users\Thimo.Koolen\source\repos\TelerikTabStripBug\TelerikTabStripBug\Pages\_Host.cshtml:line 6
at Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderPageCoreAsync(IRazorPage page, ViewContext context)
at Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderPageAsync(IRazorPage page, ViewContext context, Boolean invokeViewStarts)
at Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderAsync(ViewContext context)
at Microsoft.AspNetCore.Mvc.ViewFeatures.ViewExecutor.ExecuteAsync(ViewContext viewContext, String contentType, Nullable`1 statusCode)
at Microsoft.AspNetCore.Mvc.ViewFeatures.ViewExecutor.ExecuteAsync(ViewContext viewContext, String contentType, Nullable`1 statusCode)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextResultFilterAsync>g__Awaited|30_0[TFilter,TFilterAsync](ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResultExecutedContextSealed context)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.ResultNext[TFilter,TFilterAsync](State& next, Scope& scope, Object& state, Boolean& isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.InvokeResultFilters()
--- End of stack trace from previous location ---
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextResourceFilter>g__Awaited|25_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResourceExecutedContextSealed context)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.InvokeFilterPipelineAsync()
--- End of stack trace from previous location ---
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeAsync>g__Logged|17_1(ResourceInvoker invoker)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeAsync>g__Logged|17_1(ResourceInvoker invoker)
at Microsoft.AspNetCore.Routing.EndpointMiddleware.<Invoke>g__AwaitRequestTask|6_0(Endpoint endpoint, Task requestTask, ILogger logger)
at Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddleware.Invoke(HttpContext context)
Hi
Except of these 2 packages, are there any packages that are recommended to install?
Eric