SoundEffect.Dispose Method

Releases the resources used by the SoundEffect.

Namespace: Microsoft.Xna.Framework.Audio
Assembly: Microsoft.Xna.Framework (in microsoft.xna.framework.dll)

Syntax

public void Dispose ()

Remarks

Call Dispose only when you are finished using the SoundEffect. The Dispose method leaves the SoundEffect in an unusable state. After calling Dispose, you must release all references to the SoundEffect in order for the garbage collector to reclaim the memory that the SoundEffect was occupying. For more information, see Cleaning Up Unmanaged Resources and Implementing a Dispose Method.

See Also

Reference

SoundEffect Class
SoundEffect Members
Microsoft.Xna.Framework.Audio Namespace

Platforms

Xbox 360, Windows 7, Windows Vista, Windows XP, Windows Phone