Variable.Dispose Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
This method is inherited from the IDisposable.Dispose method, which is a mechanism to explicitly tell an object to perform cleanup.
public:
virtual void Dispose();
public void Dispose ();
abstract member Dispose : unit -> unit
override this.Dispose : unit -> unit
Public Sub Dispose ()
Implements
Examples
The following code sample shows how to dispose of variable resources.
Dispose();
Dispose()
Remarks
Dispose is an optional mechanism that should be used in specific cases that require it.