Platform SDK: DirectX

Step 1: Initialize COM

[Visual Basic]

This tutorial pertains only to applications written in C++. See DirectMusic Visual Basic Tutorials.

[C++]

Before making any calls to DirectMusic, you have to initialize COM as follows:

if (FAILED(CoInitialize(NULL)))
{
    // Terminate the application.
}   // Else full speed ahead!

Next: Step 2: Create the Performance