2

Is there ever a valid reason to use the Close method on a stream instead of Dispose?

Edd
  • 703
  • 7
  • 23
  • and another http://stackoverflow.com/questions/4153595/close-or-dispose - basically if it impliments `IDisposable` using *cough* `using` blocks does _effectively_ the same thing. – Gabe Feb 08 '16 at 17:37

1 Answers1

2

Only in System.Windows.Forms.Form and System.Data.SqlClient.SQLConnectoin do Close and Dispose have different behavior. This has to do with dispose being hidden in situations where the behavior was not clear in context. This is more deeply explained here MSDN Difference Between Close and Dispose

Idle Crow
  • 36
  • 4
  • 1
    I know that this was a duplicate question, but this is what I was trying to get at. Thanks! – Edd Feb 08 '16 at 17:53