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

Disposing of dynamic objects eg shapes

1 Answer 60 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Czeshirecat
Top achievements
Rank 2
Iron
Iron
Czeshirecat asked on 25 Jul 2016, 08:41 AM

Hi,

If I create a shape dynamically and assign it,  who is responsible for the disposal of it?

e.g. where _buttonElement is a RadButtonElement in the code fragment below, do I need to add code to dispose of it or will the ButtonFillElement do it?

_buttonElement.ButtonFillElement.Shape = new EllipseShape();

thanks in advance.

1 Answer, 1 is accepted

Sort by
0
Dimitar
Telerik team
answered on 25 Jul 2016, 11:31 AM
Hi Claire,

Thank you for writing.

We have a code that checks if the shape is set and disposes of it when the entire element is . 

Please let me know if there is something else I can help you with. 
 
Regards,
Dimitar
Telerik by Progress
Check out the Windows Forms project converter, which aids the conversion process from standard Windows Forms applications written in C# or VB to Telerik UI for WinForms.For more information check out this blog post and share your thoughts.
Tags
General Discussions
Asked by
Czeshirecat
Top achievements
Rank 2
Iron
Iron
Answers by
Dimitar
Telerik team
Share this question
or