After upgrading from Telerik UI for .NET MAUI 13.0.0 → 13.2.0, a NullReferenceException is thrown inside SchedulerAgendaView.Init() on Windows (WinUI3) whenever a RadScheduler with an AgendaViewDefinition is used. The scheduler never renders and the app receives an unhandled exception.
Steps to Reproduce:
ContentPage (or any page) with a RadScheduler in XAML, including at least one AgendaViewDefinition in ViewDefinitions:<telerik:RadScheduler AppointmentsSource="{Binding Appointments}">
<telerik:RadScheduler.ViewDefinitions>
<telerik:AgendaViewDefinition />
<telerik:DayViewDefinition />
</telerik:RadScheduler.ViewDefinitions>
</telerik:RadScheduler>
Expected Behavior:
The scheduler renders correctly with the AgendaViewDefinition, as it did in 13.0.0.
Actual Behavior:
An unhandled NullReferenceException is thrown:
System.NullReferenceException: Object reference not set to an instance of an object.
at Telerik.Maui.Controls.Scheduler.SchedulerAgendaView.Init()
at System.Threading.Tasks.Task.<>c.<ThrowAsync>b__124_0(Object state)
at Microsoft.UI.Dispatching.DispatcherQueueSynchronizationContext.<>c__DisplayClass2_0.<Post>b__0()
Root Cause Analysis (via ILSpy decompilation):
Comparing the decompiled assemblies of 13.0.0 and 13.2.0 reveals a new override in RadScheduler introduced in 13.2.0:
// NEW in 13.2.0 — not present in 13.0.0:
protected override void OnPropertyChanged([CallerMemberName] string propertyName = null)
{
base.OnPropertyChanged(propertyName);
if (propertyName == "Parent" && Parent != null && !IsLoaded)
UpdateActiveViewDefinition();
}
This causes the following call chain to be triggered during InitializeComponent() in the page constructor — before the page is attached to a window:
RadScheduler to the page → Parent property changesOnPropertyChanged("Parent") fires → UpdateActiveViewDefinition() is calledActiveViewDefinition = ViewDefinitions[0] (the AgendaViewDefinition)OnActiveViewDefinitionChanged() → content.Rebuild() (template already applied on WinUI3)SchedulerAgendaView.Model setter → Init() is called as async voidInit(), after the first await, the continuation runs and DataBindingComplete firescompleteHandler inside Init() calls:((BindableObject)this).Dispatcher.Dispatch(async delegate { ... });
Dispatcher is null because the SchedulerAgendaView is not yet attached to a window → NullReferenceExceptionThe exception is captured by the async void state machine and re-thrown via SynchronizationContext.ThrowAsync → DispatcherQueueSynchronizationContext.Post, which matches the observed stack trace exactly.
Why it worked in 13.0.0: UpdateActiveViewDefinition() was never called from OnPropertyChanged. It was only invoked after IsLoaded = true, at which point Dispatcher is guaranteed to be non-null.
Why the condition !IsLoaded is insufficient: Parent != null does not imply a window is present. During InitializeComponent(), the element has a parent in the logical tree but is not yet attached to any Window, making Dispatcher null on BindableObject.
Workaround:
Do not declare ViewDefinitions in XAML. Instead, add them programmatically in the page's Loaded event handler, at which point Dispatcher is guaranteed to be available:
private void OnPageLoaded(object sender, EventArgs e)
{
if (scheduler.ViewDefinitions.Count == 0)
{
scheduler.ViewDefinitions.Add(new AgendaViewDefinition());
scheduler.ViewDefinitions.Add(new DayViewDefinition());
scheduler.ViewDefinitions.Add(new WeekViewDefinition());
scheduler.ViewDefinitions.Add(new MonthViewDefinition());
}
}
Suggested Fix:
Either:
Option A — Guard Dispatcher usage inside SchedulerAgendaView.Init():
// In completeHandler, before calling Dispatch:
if (((BindableObject)this).Dispatcher is { } dispatcher)
dispatcher.Dispatch(...);
Option B — Guard UpdateActiveViewDefinition() in RadScheduler.OnPropertyChanged to only run when content (the internal RadSchedulerContent) has already been set (i.e., template was applied):
if (propertyName == "Parent" && Parent != null && !IsLoaded && content != null)
UpdateActiveViewDefinition();
Option B is more conservative and closer to the original 13.0.0 behavior, since content being non-null implies the template has been applied and Dispatcher is available.
Environment:
| Telerik UI for .NET MAUI | 13.2.0 (regression from 13.0.0) |
| .NET | .NET 10 |
| Platform | Windows (WinUI3) |
| MAUI | 10.0.60 |
add a button control in which you can swipe its content
Hi Team,
We have a scenario where our license key file is hosted on a team-only file share. However, the file share only works with HTTP/S links and not a UNC path.
For example, this works perfectly:
TELERIK_LICENSE_PATH="\\internalshare\folder\telerik-license.txt"However, we cannot use
TELERIK_LICENSE_PATH="http://internalshare.com/telerik-license.txt"
Thank you,
Teddy
I noticed there is a Toggle Button available, but the Toggle Switch Button that is available for WPF is not yet available for MAUI.
Please consider adding such button for .NET MAUI suite.
When adding Telerik controls on the page and run the app on android, the following error message occurs runtime:
Java.Lang.RuntimeException stack trace --- java.lang.RuntimeException: Font asset not found /data/user/0/com.companyname.appname/cache/telerikfont.ttf at android.graphics.Typeface.createFromAsset(Typeface.java:1061)
............
This error message does not prevent the app from working as expected, but the log is full of this message.
Hi Team,
I would like to be able to have client-side filtering/sorting/grouping capabilities for large backend datasets that cannot be entirely loaded on the client.
As it stands now, the DataGrid (and other data components) can only operate on the data that is has in the local DataView. This means that I need to build a custom filtering solution that prefilters/presorts the backend data before paging and loading it into the DataGrid.
To accomplish the "full view", we need a data layer that understands both the UI as well as the backend. The Telerik UI for WPF product has an excellent solution for this, known as the WPF EntityFrameworkCoreDataSource - Overview - Telerik UI for WPF and the WPF DataServiceDataSource - Overview - Telerik UI for WPF.
If such a feature can be added to Telerik UI for MAUI, it would be an excellent bonus for the component suite in data heavy applications.
Thank you,
Peter
ListView with a TemplateSelector crashes on iOS 16 device!
<telerik:RadListView ItemTemplate="{StaticResource ActTempSelector}" ItemsSource="{Binding Suggestions}">
</telerik:RadListView>log output is the following:
2022-10-08 20:44:46.810 Xamarin.PreBuilt.iOS[1593:343579] *** NSForwarding: warning: object 0x281edbea0 of class 'Telerik_Maui_Controls_Compatibility_DataControlsRenderer_iOS_TKExtendedListView' does not implement methodSignatureForSelector: -- trouble ahead
2022-10-08 20:44:46.810 Xamarin.PreBuilt.iOS[1593:343579] *** NSForwarding: warning: object 0x281edbea0 of class 'Telerik_Maui_Controls_Compatibility_DataControlsRenderer_iOS_TKExtendedListView' does not implement doesNotRecognizeSelector: -- abort
Progress/Telerik --
I would like Telerik to extend the Microsoft .NET MAUI MediaPicker control to support the selection of MULTIPLE Photos and/or Videos from the Image Gallery.
I believe this is a reasonably standard scenario for use cases where the user takes multiple Photos or Videos with the Camera and then would like to upload them to a server for storage in a web app and database.
The current Microsoft MediaPicker supports the selection of a SINGLE item only.
.NET MAUI - Platform Integration - Media - Photos and Videos
And while there are several GitHub libraries that have done this for Xamarin.Forms (and rely on Xamarin.Essentials), they are either archived or not updated in a timely manner like a 3rd Party - Paid For - Control would be.
Even Telerik/Progress has recently done a Blog Post on how to use the Microsoft Control - Leomaris Reyes published this:
Getting Started with the Media Picker in .NET MAUI
Also, I believe this Feature Request is asking for the same feature:
https://feedback.telerik.com/maui/1552553-upload-images-file-via-in-net-maui
Now, for me personally, I only need multiple image selection. So, if that's easier without the support for the other pieces, I would be happy. To be complete, I'm thinking others would need to select multiple videos.
From Ms. Reyes Blog Post....
private async void TakePhoto(object sender, EventArgs e)
{
FileResult photo = await MediaPicker.Default.PickPhotoAsync(new MediaPickerOptions
{
Title = "Select your photo"
});
// Here, add the code that is being explained in the next step.
}The new control would have something like this:
private async void TakePhoto(object sender, EventArgs e)
{
IEnumerable<FileResult> photos = await RadMediaPicker.PickPhotosAsync(new MediaPickerOptions
{
Title = "Select your photos"
});
// Here, add the code to loop through and process the selected images
}
Please let me know if you require additional information.
Hi,
Similar to WPF: WPF DataServiceDataSource - Overview - Telerik UI for WPF
Add gRPC as an alternative to WCF.
Thanks,
Although Maui has SpreadProcessing, it lacks a matching control. For the very different WPF platform you have one I use, and it would be helpful in Maui to display and readily edit class instances with numerous properties. I realize it would be a challenge to fit into mobile screens, but I do hope you will consider it, as I am trying to get all my current WPF features into my Maui work-alike. Thank you.
David Pressman