c# - Why should graphics needs to be disposed? -


why should graphics needs disposed? pen , solidbrush?

well simple answer implement 'idisposable' need disposed.

the longer answer consume unmanaged resources need released. calling dispose directly (or using 'using' statement) can release resources rather waiting gc you.


Comments

Popular posts from this blog

c# - Getting "Internal .Net Framework Data Provider error 30" error when column has NULL value -

c++ - How to modify context menu of internet explorer using IDocHostUIHandler::ShowContextMenu? -

gcc - SSE2 instructions not working in inline assembly with C++ -