I’ve created a custom WinForms UserControl and would like to override Dispose. However the code generated by the designed already contains a Dispose method. How can I add custom cleanup code to my component?
I’ve created a custom WinForms UserControl and would like to override Dispose. However the
Share
You can move the Dispose method from the code generated file into your control cs file. I’ve used this under .net 2.0, it should work on 4.0 as well.