This is a migrated thread and some comments may be shown as answers.

Memory leak when InputMode was set

1 Answer 81 Views
DateTimePicker
This is a migrated thread and some comments may be shown as answers.
Test
Top achievements
Rank 1
Test asked on 10 Jan 2018, 08:14 AM

Hi

I need to dynamically create and delete RadDateTimePicker object. However, I can not fully delete the RadDateTimePicker. This can cause a memory leak. Let me give the sample example to illustrate my problem.

for(int b=0;b<10000;b++){

  for(int a=0;a<100;a++){
    RadDateTimePicker radDateTimePicker = new RadDateTimePicker();
    radDateTimePicker.InputMode = InputMode.DatePicker;
    radDateTimePicker = null;
  }
  long memory = GC.GetTotalMemory(true);
  System.Diagnostics.Trace.WriteLine(xxx.ToString() + " - " + (memory / 1000).ToString() + "K");
}

I found that If I set the InputMode the memory will keep increasing (Memory leak).  Otherwise, the memory will not keep increasing. Could you please help to solve this problem. 

 

Thank you very much

1 Answer, 1 is accepted

Sort by
0
Imer
Telerik team
answered on 10 Jan 2018, 12:37 PM
Hello,

Dear Test, 

May I please know if you are currently using a trial or happen to have a license with active support in another account?
I was not able to see the tools from where the question is raised under starsunmoongod@gmail.com.

Please do keep me updated so that I may give the support team as much information as possible in case that they may need it. 

I await your response!

Thank you and may you have a great day!


Regards,
Imer
Progress Telerik
Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which you to write beautiful native mobile apps using a single shared C# codebase.
Tags
DateTimePicker
Asked by
Test
Top achievements
Rank 1
Answers by
Imer
Telerik team
Share this question
or