Hi, my application layout has 2 default drawer (left one as Push and Right one as Overlay).
To handle this layout i used the suggestion on:
https://www.telerik.com/forums/nested-drawer-for-menu-on-left-and-right
The application is managed with this gerarchy:
- Right drawer
- Left drawer inside right drawer content
- Application components inside Left drawer content
Now i need a side panel inside of some application compoents: note who i don't need menu items, but only a side panel with a custom component on it, but i have not found a telerik component to handle it.
There is a telerik component to handle an overlay side panel (other than TelerikDrawer)?
I tried to add another TelerikDrawer with a custom template, but is seem not working.
Adding a Drawer in one of my application components result in unexpected behaviour: the left drawer is rendered on the right side of the screen.
Any suggestion? thanks
Out of the box, after updating today to 7.1.0, converted the Weather page from table to TelerikGrid component and the date was being displayed with coma as separator. My html tag's lang was set to en-US, and the SatelliteResourceLanguage property was set to en-US, my OS's regional setting is US and yet the display was European culture.
var cult = CultureInfo.GetCultureInfo( "en-US" );
CultureInfo.DefaultThreadCurrentCulture = cult;
CultureInfo.DefaultThreadCurrentUICulture = cult;
Adding the above code, resolved the issue. But my expectation is to default to the system's culture even when the application is supporting globalization/localization.
Hi,
I couldn't find any articles about customizing Telerik components with additional properties,
but want to add my own property directly to a Telerik component, like this:
<TelerikWindow MyOwnProperty="SomeValue" />
I would like to avoid creating a custom wrapper component where I would use the Telerik component inside.
Is there any way to achieve this directly with Telerik components without having to wrap them?
Huge thanks for your response,
Bohdan
I want to have a MultiSelect experience for a field in a ListView editor. I'd like the binding to work with the model's navigation collection instead of an ancillary Id collection.
Take the following example where we have a ListView of Appointments. An Appointment has a collection of Contacts called Attendees that we want to manage on Create and Edit with a MultiSelect.
TelerikMultiSelect doesn't like a bind-value with a collection of objects - it wants Ids. One way to solve this could be to do gymnastics with an extra AttendeeIds collection on the Appointment and synchronize that collection with the navigation entities on read/create/update. Is there a way to avoid the gymnastics and solve this case more directly?
Can you provide an example? Thanks.
<TelerikListView TItem="Appointment"...>
...
<EditTemplate>
<TelerikMultiSelect Data="@Contacts" Placeholder="Select attendees" AutoClose="false"
@bind-Value="@context.Attendees" <-this does not work
TextField="@nameof(Contact.Name)" ValueField="@nameof(Contact.Id)"
DebounceDelay="0" />
</EditTemplate>
...
</TelerikListView>
List<Contact> Contacts {get; set;} =[]; //loaded in oninitializeasync
public class Appointment {
public Guid Id {get; set;}
public List<Contact> Attendees {get; set;}
}
public class Contact {
public Guid Id {get; set;}
public string Name {get; set;}
}
...
I'm receiving the following error when I tab from the last row in group to the next group.
Unhandled exception rendering component: No parameterless constructor
defined for type 'Telerik.Blazor.Components.Grid.Grouping.GridGroup'.
System.MissingMethodException:
No parameterless constructor defined for type
'Telerik.Blazor.Components.Grid.Grouping.GridGroup'.
Here is my grid.
<TelerikGrid @ref="@TheGrid" Data="Mappings"
Groupable="true"
OnStateInit="@((GridStateEventArgs<object> args) => OnStateInitHandler(args))"
OnRead="@ReadHandler"
OnUpdate="@UpdateHandler"
EditMode="@GridEditMode.Incell"
Pageable="true"
PageSize="15" RowHeight="32"
Navigable="true" Sortable="true">
<GridToolBarTemplate>
<GridSearchBox Width="200px"></GridSearchBox>
<span class="k-toolbar-spacer"></span>
<GridCommandButton Command="ExcelExport" Icon="@SvgIcon.FileExcel">Export to Excel</GridCommandButton>
<GridCommandButton Command="CsvExport" Icon="@SvgIcon.FileCsv">Export to CSV</GridCommandButton>
</GridToolBarTemplate>
<GridColumns>
<GridColumn Field="@nameof(SiteMappingDto.SiteName)" FieldType="@typeof(string)" Title="Site" Editable="false" />
<GridColumn Field="@nameof(SiteMappingDto.SiteReference)" FieldType="@typeof(string)" Title="Reference" Editable="false" />
<GridColumn Field="@nameof(SiteMappingDto.TagName)" FieldType="@typeof(string)" Title="Tag" Editable="false" />
<GridColumn Field="@nameof(SiteMappingDto.TagDescription)" FieldType="@typeof(string)" Title="Description" Editable="false" />
<GridColumn Field="@nameof(SiteMappingDto.MappingValue)" FieldType="@typeof(string)" Title="Value" Editable="true" />
</GridColumns>
</TelerikGrid>
And the dto used:
public class SiteMappingDto
{
public SiteMappingDto()
{
}
public int Id { get; set; }
public string? SiteName { get; set; }
public string? SiteReference { get; set; }
public string? TagName { get; set; }
public string? TagDescription { get; set; }
public int TagOrder { get; set; }
public string? MappingValue { get; set; }
}
Hi, here's the scenario.
The time picker defaults to 0:00:00 <TimeOnly>:
<TelerikTimePicker ID="txtPlayStart"
@bind-Value="Value.playStart"
Format="H:mm:ss"
T="TimeOnly"
ShowClearButton="true"/>
the user enters a time, saves it, all is well.
He realizes later he entered a bad time and wants to clear it.
He clicks the clear button, and saves it.
Imagine his surprise when nothing changes?
clear doesn't set it back to the default of 0:00:00? there's a visual cue for the user (control is in red), but forcing them to enter 0:00:00 is not really appropriate?
Furthermore, if I catch the OnChange event, it fires when the user clicks the clear button, and it says the time is what it was before the user clicked clear. :/
I'm using the 7.1.0 that just came out yesterday.
I'm coming to realize that many of the Telerik Blazor components are pretty "bare bone" and some some sort of developer wrapper is required to make them user friendly. (Except for "big" ones like the grid.) Is that intentional?
I'm not seeing a way around this short of using the code and building my own custom version that I then have to keep up to date with every new release?
Thanks,
Charles
I'm working from this demo to use NoDataTemplate with a TelerikChart. The demo works for me in the link but locally, the NoDataTemplate is always visible regardless of whether there's data in the chart. I copied the files from that demo to a test project and still can't get the NoDataTemplate to disappear.
I have the test project here and the chart is in the Test.razor page.
I want to show a series of pie charts but with the series labels on top of each section like so:
I haven't found anything that suggests the labels can be anywhere except attached by lines. Is this possible?
Hi, sorry if this is a basic question, but I cannot for the life of me figure out how to get this to work. I can have a DropDown list and a form separately, but when I try to put the DropDown into the form itself, I get a "Object of type 'Telerik.Blazor.Components.FormItem' does not have a property matching the name 'ChildContent'" error.
Here's a sample snippet of what I'm trying to do:
<TelerikForm Model="@Input"
Columns="3"
ColumnSpacing="50px"
OnValidSubmit="@HandleValidSubmit"
OnInvalidSubmit="@HandleInvalidSubmit">
<FormValidation>
<DataAnnotationsValidator />
</FormValidation>
<FormItems>
<FormItem Field="@nameof(Model.Attribute)"></FormItem>
<FormItem Field="@nameof(Model.Attribute2)">
<TelerikDropDownList Data="@myDdlData"
TextField="MyTextField"
ValueField="MyValueField"
@bind-Value="Model.Attribute3">
</TelerikDropDownList>
</FormItem>
<FormItem Field="@nameof(Model.Attribute4)"></FormItem>
</FormItems>
</TelerikForm>
<TelerikAutoComplete Data="@VeicoloAutoCompleteData"
Value="@VeicoloAutoCompleteValue"
ValueChanged="@( (string newValue) => OnVeicoloAutoCompleteValueChanged(newValue) )"
OnChange="@OnChangeVeicoloAutoComplete"
ValueField="@( nameof(DropDownModel.Text) )"
MinLength="3"
DebounceDelay="150">
<ItemTemplate>
<strong>@context.Text</strong>
</ItemTemplate>
</TelerikAutoComplete>
private List<DropDownModel> VeicoloAutoCompleteData { get; set; } = new();
private string VeicoloAutoCompleteValue { get; set; }
private async Task OnVeicoloAutoCompleteValueChanged(string newValue)
{
if (newValue.Length < 3)
{
VeicoloAutoCompleteValue = newValue;
return;
}
var request = new DataSourceRequest()
{
Skip = 0,
Filters = new List<IFilterDescriptor>(),
Sorts = new List<SortDescriptor>(),
Aggregates = new List<AggregateDescriptor>(),
Groups = new List<GroupDescriptor>()
};
request.Page = 1;
request.PageSize = 10;
var fs1 = new FilterDescriptorCollection();
fs1.Add(new FilterDescriptor("Targa", FilterOperator.Contains, newValue));
request.Filters = new List<IFilterDescriptor>()
{
new CompositeFilterDescriptor()
{
FilterDescriptors = fs1,
LogicalOperator = FilterCompositionLogicalOperator.Or,
}
};
var veicoli = await _veicoloService.GetAll(request);
VeicoloAutoCompleteValue = newValue;
VeicoloAutoCompleteData = veicoli.ToDropDownModel();
}
private DropDownModel? userChoiceVeicolo;
private async void OnChangeVeicoloAutoComplete(object theUserChoice)
{
if (userChoiceVeicolo is not null && userChoiceVeicolo.Text.Equals((string)theUserChoice, StringComparison.InvariantCultureIgnoreCase))
{
return;
}
var choice = VeicoloAutoCompleteData.FirstOrDefault(x => x.Text.Equals((string)theUserChoice, StringComparison.InvariantCultureIgnoreCase));
userChoiceVeicolo = choice;
if(userChoiceVeicolo is not null)
_veicolo = await _veicoloService.GetById(userChoiceVeicolo.Value);
}