DirectX SDK

DirectMusicLoader.LoadStyleFromResource

The DirectMusicLoader.LoadStyleFromResource method loads a style object from a resource.

object.LoadStyleFromResource( _
    moduleName As String, _
    resourceName As String) As DirectMusicStyle

Parameters

object
Object expression that resolves to a DirectMusicLoader object.
moduleName
Name of the module containing the resource.
resourceName
Identifier of the resource containing the style object. The resource must be of type "DMSTYLE".

Return Values

If the method succeeds, it returns a DirectMusicStyle object.

Error Codes

If the method fails, it raises an error, and Err.Number can be set to one of the following values:

DMUS_E_FAIL
DMUS_E_INVALIDARG
DMUS_E_OUTOFMEMORY
DMUS_E_LOADER_FAILEDOPEN
DMUS_E_LOADER_FAILEDCREATE
DMUS_E_LOADER_FORMATNOTSUPPORTED

See Also

DirectMusicLoader.LoadStyle