Telerik Forums
UI for .NET MAUI Forum
1 answer
47 views

Edit: RadTabView also leaks. Attached new sample app.

We have found leaks in these controls. I have attached a sample app that demonstrates the problem.

I have logged a support ticket but is anyone else experience similar leaks with these controls?

From the included readme.md:-


Description

Memory leaks when using

  • Telerik RadDataGrid
  • Telerik RadCalendar
  • Telerik RadAutoComplete
  • Telerik RadTabView

Configuration

  • Dotnet 8
  • Telerik.UI.for.Maui 6.6 (also happens with 6.5)
  • Windows 10

Steps to reproduce

Build and run application

  1. Run publish.ps1 to build the application in release mode
  2. Run _temp/publish/Maui-Memleaks.exe

Leaks for every instance (RED buttons)

  1. Click a RED button.
  2. Close the "Close" button
  3. Click the "GC.Collect" button. Note that the "Alive" count will keep increasing every time you click a RED button (ie memory leak)

Leaks for last instance (ORANGE buttons)

  1. Click a ORANGE button.
  2. Close the "Close" button
  3. Click the "GC.Collect" button. Note that the "Alive" count will only increase the first time (ie memory leak), on subsequent clicks the "Release" count will increase.

No leaks (GREEN buttons)

  1. Click a GREEN button.
  2. Close the "Close" button
  3. Click the "GC.Collect" button. Note that the "Release" count will always increase (ie no leaks)
Yana
Telerik team
 answered on 23 Jan 2024
1 answer
27 views

Hi,

i have a scenario where I as loggedIn user belongs to some Organization and in UsersView I can see all users and also one of the columns is Organization. I would like to set filter of this column to same Organization as Im in. So I see only users from my organization by default.

 

so my question is how to set this filter from code or can i somehow bind it from xaml to some property ?

Didi
Telerik team
 answered on 19 Jan 2024
1 answer
17 views

I am trying to get the background color for the RadDatePicker to be white. It is picking up a color that I am unaware of specifying ( read I did not do it intentionally :-) )

I found general styling instructions for the controls that indicated the proper way would be to create a style...

<Style TargetType="Label" x:Key="DateDisplayLabelStyle">
  <Setter Property="TextColor" Value="#007A53"/>
  <Setter Property="BackgroundColor" Value="White"/>
</Style>

I am unsure how to get the lighter green color set to white. I did not see a name for this part of the control in the documentation.

 

Thanks

-Sean

Didi
Telerik team
 answered on 19 Jan 2024
1 answer
45 views

 

I'm trying to build a donet maui app but when it try to run the project in ios emulator i get this error, i don't know what to do (only happens for emulator, can run the project to ios devices)

/usr/local/share/dotnet/packs/Microsoft.iOS.Sdk/16.4.7125/targets/Xamarin.Shared.Sdk.targets(1276,3): error : clang++ exited with code 1: [/Users/carminamoreno/Documents/LosAlamosMAUI/Los Alamos MAUI/AppPedidosMobile/AppPedidosMobile.csproj::TargetFramework=net7.0-ios]
/usr/local/share/dotnet/packs/Microsoft.iOS.Sdk/16.4.7125/targets/Xamarin.Shared.Sdk.targets(1276,3): error : ld: warning: ignoring duplicate libraries: '-lSystem.IO.Compression.Native', '-lSystem.Native', '-lSystem.Net.Security.Native', '-lSystem.Security.Cryptography.Native.Apple', '-lc++', '-lmono-component-debugger', '-lmono-component-diagnostics_tracing', '-lmono-component-hot_reload', '-lmonosgen-2.0', '-lxamarin-dotnet-debug', '-lz' [/Users/carminamoreno/Documents/LosAlamosMAUI/Los Alamos MAUI/AppPedidosMobile/AppPedidosMobile.csproj::TargetFramework=net7.0-ios]
/usr/local/share/dotnet/packs/Microsoft.iOS.Sdk/16.4.7125/targets/Xamarin.Shared.Sdk.targets(1276,3): error : ld: building for 'iOS-simulator', but linking in object file (/Users/carminamoreno/Documents/LosAlamosMAUI/Los Alamos MAUI/AppPedidosMobile/obj/Debug/net7.0-ios/iossimulator-arm64/linker-cache/TelerikUI.a[arm64][2](TKChartAnnotation.o)) built for 'iOS' [/Users/carminamoreno/Documents/LosAlamosMAUI/Los Alamos MAUI/AppPedidosMobile/AppPedidosMobile.csproj::TargetFramework=net7.0-ios]
/usr/local/share/dotnet/packs/Microsoft.iOS.Sdk/16.4.7125/targets/Xamarin.Shared.Sdk.targets(1276,3): error : clang: error: linker command failed with exit code 1 (use -v to see invocation) [/Users/carminamoreno/Documents/LosAlamosMAUI/Los Alamos MAUI/AppPedidosMobile/AppPedidosMobile.csproj::TargetFramework=net7.0-ios]

Didi
Telerik team
 answered on 17 Jan 2024
1 answer
15 views

In day view, is it possible to change the times from 24hr to 12hr AM/PM style?

I've tried setting the Culture and all that but no luck.

Didi
Telerik team
 answered on 16 Jan 2024
1 answer
28 views

  I wanted to know if there were any known issues with the ImageEditor on iOS? In the documentation it had examples on android and windows but nothing for iOS. And then i get the crash (Down below) stating a maui context issue.

~ Additional info 

I have the ImageEditor in a 'mopup' page to act as a popup. 

The styling on the editor is only affecting TextColor                                            

simulator(built on x64)  and physical devices 

iOS 17 

.NET8

 

<Grid Grid.Row="0">
                  <Grid.RowDefinitions>
                      <RowDefinition Height="*"/>
                      <RowDefinition Height="Auto" />
                  </Grid.RowDefinitions>

                  <telerik:RadImageEditor
                      x:Name="imageEditor"
                      Padding="10" />

                  <telerik:RadImageEditorToolbar
                      Grid.Row="1"
                      AutoGenerateItems="False"
                      ImageEditor="{x:Reference imageEditor}">
                      <telerik:ImageEditorRotateLeftToolbarItem Style="{StaticResource buttonToolbarStyle}" />
                      <telerik:ImageEditorRotateRightToolbarItem Style="{StaticResource buttonToolbarStyle}" />
                      <telerik:ImageEditorUndoToolbarItem Style="{StaticResource buttonToolbarStyle}" />
                      <telerik:ImageEditorRedoToolbarItem Style="{StaticResource buttonToolbarStyle}" />
                      <telerik:ButtonToolbarItem
                          x:Name="SaveToolBar"
                          Clicked="OnSaveTapped"
                          IsEnabled="True"
                          IsVisible="True"
                          Style="{StaticResource buttonStyle}"
                          Text="Save" />
                  </telerik:RadImageEditorToolbar>
              </Grid>

1st crash message 
System.InvalidOperationException: 'Loading...'

 

follow up crash messages / detailed log 

ObjCRuntime.ObjCException: 'Objective-C exception thrown.  Name: System.InvalidOperationException Reason: MauiContext should have been set on parent. (System.InvalidOperationException)
   at Microsoft.Maui.Platform.ElementExtensions.ToPlatform(IElement view)
   at Microsoft.Maui.Handlers.LayoutHandler.Remove(IView child)
   at Microsoft.Maui.Handlers.LayoutHandler.MapRemove(ILayoutHandler handler, ILayout layout, Object arg)
   at Microsoft.Maui.CommandMapper`2.<>c__DisplayClass6_0[[Microsoft.Maui.ILayout, Microsoft.Maui, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null],[Microsoft.Maui.ILayoutHandler, Microsoft.Maui, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].<Add>b__0(IElementHandler h, IElement v, Object o)
   at Microsoft.Maui.CommandMapper.InvokeCore(String key, IElementHandler viewHandler, IElement virtualView, Object args)
   at Microsoft.Maui.CommandMapper.Invoke(IElementHandler viewHandler, IElement virtualView, String property, Object args)
   at Microsoft.Maui.Handlers.ElementHandler.Invoke(String command, Object args)
   at Microsoft.Maui.Controls.Layout.NotifyHandler(String action, Int32 index, IView view)
   at Microsoft.Maui.Controls.Layout.OnRemove(Int32 index, IView view)
   at Microsoft.Maui.Controls.Layout.RemoveAt(Int32 index)
   at Microsoft.Maui.Controls.Layout.Remove(IView child)
   at Telerik.Maui.Controls.ImageEditor.BusyService.HideBusyIndicatorCore()
   at Microsoft.Maui.Dispatching.Dispatcher.<>c__DisplayClass9_0.<DispatchImplementation>b__0()
   at CoreFoundation.DispatchQueue.static_dispatcher_to_managed(IntPtr context) in /Users/builder/azdo/_work/1/s/xamarin-macios/src/CoreFoundation/Dispatch.cs:line 379
   at UIKit.UIApplication.UIApplicationMain(Int32 argc, String[] argv, IntPtr principalClassName, IntPtr delegateClassName) in /Users/builder/azdo/_work/1/s/xamarin-macios/src/UIKit/UIApplication.cs:line 58
   at UIKit.UIApplication.Main(String[] args, Type principalClass, Type delegateClass) in /Users/builder/azdo/_work/1/s/xamarin-macios/src/UIKit/UIApplication.cs:line 94
   at MyApp.Program.Main(String[] args) in C:\Development\Xamarin Field Clients\MyApp\MyApp\Platforms\iOS\Program.cs:line 13

Native stack trace:
0   CoreFoundation                      0x0000000113ce728d __exceptionPreprocess + 242
1   libobjc.A.dylib                     0x000000012a18c894 objc_exception_throw + 48
2   libxamarin-dotnet-debug.dylib       0x000000010e8d9fe6 xamarin_process_managed_exception + 934
3   libxamarin-dotnet-debug.dylib       0x000000010e8d9b8b xamarin_process_managed_exception_gchandle + 59
4   libxamarin-dotnet-debug.dylib       0x000000010e8d9b45 xamarin_ftnptr_exception_handler + 21
5   libmonosgen-2.0.dylib               0x000000010fdd1d77 mono_handle_exception_internal + 6199
6   libmonosgen-2.0.dylib               0x000000010fdd0535 mono_handle_exception + 21
7   libmonosgen-2.0.dylib               0x000000010fe48389 interp_throw + 185
8   libmonosgen-2.0.dylib               0x000000010fe464dc interp_throw_ex_general + 188
9   libmonosgen-2.0.dylib               0x000000010fe40705 mono_interp_exec_method + 38437
10  libmonosgen-2.0.dylib               0x000000010fe48f65 interp_entry + 453
11  libmonosgen-2.0.dylib               0x000000010fe49797 interp_entry_static_1 + 55
12  ???                                 0x000000010d73b924 0x0 + 4520655140
13  libdispatch.dylib                   0x0000000130899ac0 _dispatch_main_queue_drain + 1420
14  libdispatch.dylib                   0x0000000130899526 _dispatch_main_queue_callback_4CF + 31
15  CoreFoundation                      0x0000000113c43850 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 9
16  CoreFoundation                      0x0000000113c3e18b __CFRunLoopRun + 2463
17  CoreFoundation                      0x0000000113c3d409 CFRunLoopRunSpecific + 557
18  GraphicsServices                    0x00000001322be187 GSEventRunModal + 137
19  UIKitCore                           0x00000001437583a2 -[UIApplication _run] + 972
20  UIKitCore                           0x000000014375ce10 UIApplicationMain + 123
21  libxamarin-dotnet-debug.dylib       0x000000010e8a94da xamarin_UIApplicationMain + 58
22  libmonosgen-2.0.dylib               0x000000010fe48bc5 do_icall + 341
23  libmonosgen-2.0.dylib               0x000000010fe47357 do_icall_wrapper + 295
24  libmonosgen-2.0.dylib               0x000000010fe38076 mono_interp_exec_method + 3990
25  libmonosgen-2.0.dylib               0x000000010fe357e3 interp_runtime_invoke + 259
26  libmonosgen-2.0.dylib               0x000000010ff1b908 mono_runtime_invoke_checked + 136
27  libmonosgen-2.0.dylib               0x000000010ff230db mono_runtime_exec_main_checked + 107
28  libmonosgen-2.0.dylib               0x000000010fd87f52 mono_jit_exec + 354
29  libxamarin-dotnet-debug.dylib       0x000000010e8edbba xamarin_main + 1898
30  MyApp                               0x000000010482f114 main + 68
31  dyld                                0x000000010d4653ee start_sim + 10
32  ???                                 0x00000002052e73a6 0x0 + 8676864934
'
Didi
Telerik team
 answered on 15 Jan 2024
1 answer
19 views

I am looking to set a custom tooltip on a ButtonToolbarItem.  It appears the current tooltip only binds to the Text property.

Is there a way for me to change the ToolTipProperties.TextProperty binding?

Didi
Telerik team
 answered on 12 Jan 2024
0 answers
16 views

I am trying to use the pie chart on my content page but it is not rendering. My XAML is:

                        <telerik:RadPieChart Grid.Row="0" x:Name="chart" HandlerChanged="chart_HandlerChanged">
                           <telerik:RadPieChart.BindingContext>
                                <vm:SystemStatsViewModel />
                            </telerik:RadPieChart.BindingContext>
                            <telerik:RadPieChart.Series>
                                <telerik:PieSeries ShowLabels="True"
                                    RadiusFactor="0.8"
                                    ValueBinding="Value"
                                    ItemsSource="{Binding LoadChartItems}" />
                            </telerik:RadPieChart.Series>
                        </telerik:RadPieChart>

The view model returns sample data just to get the chart to render:

        public ObservableCollection<LoadChartItem> LoadChartItems { get => new() {
        new() { Category = "Test1", Value = 52 },
        new() { Category = "Test2", Value = 19 },
        new() { Category = "Test3", Value = 82 },
        new() { Category = "Test4", Value = 23 }
        };
        }

There are other controls (labels, grids) on the page that render properly using the view model so I can rule out a bug in my view model. I have tried rendering the chart with and without the:

                           <telerik:RadPieChart.BindingContext>
                                <vm:SystemStatsViewModel />
                            </telerik:RadPieChart.BindingContext>

since the page references the SystemStatsViewModel in the bindingcontext. The control just never appears or throws an error of any kind. Any help or insights are appreciated.

Jude
Top achievements
Rank 1
 asked on 10 Jan 2024
1 answer
27 views
Hi,

Just a quick Question; Re the DockLayout, It looks like it would work the same as the standard MAUI grid, what is the main difference and advantages of using this instead?
Yana
Telerik team
 answered on 04 Jan 2024
1 answer
25 views

Hi Telerik Team,

May I kindly ask you if I could use ListView control in .NET MAUI with already grouped structure data type? I guess I could flatten my object source model, but I am interested if it is possible to use below model with ListView control and grouping options?

I have a ViewModel with a property type of ObservableCollection<T> MyProperty where T defined as:
public class T : List<T1>
{
public string Name {get;set;}
public string Area {get;set;}
}
and T1 as below:
public class T1
{
public string Id {get;set;}
public string ImgURL {get;set;}
//..some other properties
}

Yana
Telerik team
 answered on 04 Jan 2024
Top users last month
Dominik
Top achievements
Rank 1
Giuliano
Top achievements
Rank 1
Dominic
Top achievements
Rank 1
Glendys
Top achievements
Rank 1
NoobMaster
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?