I'm using a TelerikAutoComplete as a filter/searchbox for a Grid. I'm using the OnChange event to call a method that gets the filtered Grid data. It works great until the user clicks the (Add) button to add a new record. At this point, the OnChange event fires again because the OnChange also fires for the OnBlur.
The effect is that the user clicks the Add button and they see the spinner in the TelerikLoaderContainer for a second or less, and then they have to click the button again to actually fire the event for the button.
I need to move focus away from the AutoComplete after the first OnChange fires, but FocusAsync() doesn't exist for a TelerikGrid or GridCommandButton.
I am using the tiles from openstreetmap and would like to apply a dark mode theme to the Blazor Map component. There is mention of using the Sass Theme Builder on the overview page, but the Map is not one of the components listed.
Is this possible?
Thanks for any help on this topic.
Hi,
Rendering the whole TelerikGrid in Blazor can be slow when there are lots of rows. How do I update the value in a single cell or row, without re-rendering the whole grid?
I am trying to follow https://www.telerik.com/blogs/azure-devops-and-telerik-nuget-packages
but I keep getting error NU1403: Package content hash validation failed for Telerik.Recurrence.Trial.0.2.0. The package is different than the last restore.
This error is generated because my committed packages.lock.json (which is generated by RestorePackagesWithLockFile = true) is somehow different, even though I use the same credentials.
What can I do?
I just installed the Blazor UI components following this article: https://docs.telerik.com/blazor-ui/getting-started/server-blazor
I added "@layout TelerikLayout" to MainLayout.razor and I get a build error:
Error CS0246 The type or namespace name 'TelerikLayout' could not be found (are you missing a using directive or an assembly reference?)
The source is Shared_MainLayout_razor.g.cs. I've tried the typical 'clean & rebuild' as well as restarting VS. Any suggestions?
Hi,
I'd like to set the selected items of a treeview from an async method. The values to set come from an web api. So it's an async call.
I tested the case with the provided Telerik sample. With version 2.25 it works. With the latest version selected items are not set within the treeview.
What do I miss?
@page "/"
<TelerikTreeView Data="@FlatData"
CheckBoxMode="@TreeViewCheckBoxMode.Multiple"
CheckParents="@true"
CheckChildren="@true"
CheckOnClick="@false"
@bind-CheckedItems="@SelectedItems">
</TelerikTreeView>
@code {
List<TreeItem> FlatData { get; set; }
IEnumerable<object> SelectedItems { get; set; } = new List<object>();
protected override async Task OnInitializedAsync()
{
await GenerateData();
await SelectDefault();
}
async Task SelectDefault()
{
await Task.Delay(100);
SelectedItems = FlatData.Where(data => data.Id == 2);
}
async Task GenerateData()
{
FlatData = new List<TreeItem>();
FlatData.Add(new TreeItem()
{
Id = 1,
Text = "Project",
ParentId = null,
HasChildren = true,
Icon = "folder",
Expanded = true
});
FlatData.Add(new TreeItem()
{
Id = 2,
Text = "Design",
ParentId = 1,
HasChildren = true,
Icon = "brush",
Expanded = true
});
FlatData.Add(new TreeItem()
{
Id = 3,
Text = "Implementation",
ParentId = 1,
HasChildren = true,
Icon = "folder",
Expanded = true
});
}
public class TreeItem
{
public int Id { get; set; }
public string Text { get; set; }
public int? ParentId { get; set; }
public bool HasChildren { get; set; }
public string Icon { get; set; }
public bool Expanded { get; set; }
}
}
Hi,
I am using TelerikCalendar Blazor component and set its SelectionMode="@CalendarSelectionMode.Multiple".
It works fine on computer as there is CTRL key to hold and click multiple dates to select them.
My question is how to make multi-selection on mobile/touch screen devices. There is no CTRL key.
How does TelerikCalendar support mult-selection on those devices?
Thanks
Kan
<TelerikFilter @ref="@FilterControl" Value="@Value" ValueChanged="@OnValueChanged">
<FilterFields >
@foreach (SearchFieldConfiguration searchField in SearchFields)
{
<FilterField Name="@nameof(@searchField.DisplayName)" Type="@(Type.GetType(@searchField.Type))" Label="@searchField.DisplayName" />
}
</FilterFields>
</TelerikFilter>
This is driving me nuts.
I have tried the .clear() and I have tried re-init the object. Nothing seems to clear this from the UI that the user sees.
on the razor page:
<TelerikMultiSelect @ref="DDLFil1"
Class="my-multiselect"
Data="@DDLFil1List"
TextField="Result"
TItem="DDLList"
ValueField="Result"
TValue="string"
Placeholder="Select the items you need"
AutoClose="false"
Filterable="true"
ClearButton="true"
>
<MultiSelectSettings>
<MultiSelectPopupSettings Height="500px" />
</MultiSelectSettings>
<HeaderTemplate>
<label style="padding: 4px 8px;">
<TelerikCheckBox TValue="bool" Value="@DDLFil1_IsAllSelected()" ValueChanged="@( (bool v) => DDLFil1_ToggleSelectAll(v) )"></TelerikCheckBox>
Select All
</label>
</HeaderTemplate>
</TelerikMultiSelect>
In the CS behind the code page:
public TelerikMultiSelect<DDLList, string> DDLFil1 { get; set; } // Ctrl on the webpage
private bool blnHideDDLFil1 { get; set; } = true;
string DDLFil1Lbl = "";
List<DDLList> DDLFil1List = new List<DDLList>();
string? _DDLFil1SelectedId;
string DDLFil1SelectedId
{
get
{
return _DDLFil1SelectedId;
}
set
{
_DDLFil1SelectedId = value;
}
}
List<string> DDLFil1Values { get; set; } = new List<string>();
List<string> DDLFil1Results { get; set; } = new List<string>();
Clearing code:
if (DDLFil1.Value != null)
{
if (DDLFil1.Value.Count() > 0)
{ // Items have been selected!
DDLFil1.Value.Clear();
};
};
How does one Clear the selected items for the user to re-use without having them to unselect each item.
You have a ClearSelectAll Button on the Control. sometimes hard for the user to see it with multiple items selected.
Would be nice if i could call that in code!!!
DDLFil1.ClearSelectedAll();
I really need this feature.
Thanks