Copyright © 2013-2014 MultiMedia Soft

MidiDevices.Close method

Previous pageReturn to chapter overviewNext page



Closes a specific MIDI device installed inside the system which was previously opened through the MidiDevices.Open method.


When a MIDI device has been closed through this method, eventual connections with the specific MIDI input or output device, previously established through calls to MidiDevices.InputOutputConnect, MidiVirtualKeyboard.MidiInputConnect, MidiVirtualKeyboard.MidiOutputConnect or MidiDjConsole.Connect methods, will be automatically disconnected.


For further details about the use of MIDI devices see the ClassMidiDevices class section and the How to manage MIDI devices tutorial.





[Visual Basic]

MidiDevices.Close (

nDeviceUniqueId as Int16

) as enumDjcErrorCodes



public enumDjcErrorCodes MidiDevices.Close (

Int16 nDeviceUniqueId




public: enumDjcErrorCodes MidiDevices.Close (

Int16 nDeviceUniqueId








The unique identifier of the MIDI device returned by a previous call to the MidiDevices.Open method



Return value






Negative value

An error occurred. Check the LastError property value in order to see the last error.

enumDjcErrorCodes.ERR_DJC_NOERROR (0)

The method call was successful.