NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

CodeStream.Dispose

Disposes of the resources (other than memory) being used by the CodeStream.

[Visual Basic]
MustOverride Public Sub Dispose()
[C#]
public abstract void Dispose();
[C++]
public: virtual void Dispose() = 0;
[JScript]
public abstract function Dispose();

Remarks

This method is called when the CodeStream is no longer needed. This method is typically called when the document is closed by the user. The CodeStream should remove any events it had connected to. This method will be called only once.

Call Dispose when you are finished using the CodeStream. The Dispose method leaves the CodeStream in an unusuable state. After calling Dispose, you must release all references to the CodeStream so the memory it was occupying can be reclaimed by garbage collection.

Always call Dispose before you release your last reference to the CodeStream. Otherwise, the resources the CodeStream is using will not be freed until garbage collection calls the CodeStream object's destructor.

See Also

CodeStream Class | CodeStream Members | System.ComponentModel.Design Namespace