DirectX SDK

DirectInputEffect.Unload

The DirectInputEffect.Unload method removes the effect from the device. If the effect is playing, it is automatically stopped before it is unloaded.

object.Unload()

Parameters

object
Object expression that resolves to a DirectInputEffect object.

Error Codes

If the method fails, an error is raised and Err.Number may be set to one of the following:

DIERR_INPUTLOST
DIERR_INVALIDPARAM
DIERR_NOTEXCLUSIVEACQUIRED
DIERR_NOTINITIALIZED

Remarks

The device must be acquired at the exclusive cooperative level for this method to succeed.