DirectX SDK

DirectMusicSegment.SetLength

The DirectMusicSegment.SetLength method sets the length of the segment.

object.SetLength(mtLength As Long)

Parameters

object
Object expression that resolves to a DirectMusicSegment object.
mtLength
Desired length, in music time. Must be greater than 0.

Error Codes

If the method fails, it raises an error, and Err.Number can be set to DMUS_E_OUT_OF_RANGE.

Remarks

In most cases, applications do not need to set the length, which is automatically set when the segment is loaded. However, this method can be used to shorten a segment.

See Also

DirectMusicSegment.GetLength