Copyright © 2013-2015 MultiMedia Soft

MidiDjConsole.ProfileButtonMidiCommandGet method

Previous pageReturn to chapter overviewNext page

Remarks

 

Obtains parameters of the short MIDI command specific for a button item stored inside the profile. See the MidiDjConsole.ProfileButtonMidiCommandSet method for details about the structure of a short MIDI command representing a push button item.

 

The combination of MIDI command parameters is usually defined inside the technical specifications of the physical DJ Console and may vary a lot depending upon the DJ Console in use.

 

For further details about interfacing with MIDI DJ Consoles see the MidiDjConsole object section and the How to manage MIDI DJ consoles tutorial.

 

 

Syntax

 

[Visual Basic]

MidiDevices.MidiDjConsole.ProfileButtonMidiCommandGet (

strItemName as String,

ByRef nMidiCommandPressed as Int16,

ByRef nMidiCommandReleased as Int16,

ByRef nMidiChannel as Int16,

ByRef nMidiDataPressed as Int16,

ByRef nMidiDataReleased as Int16

) as enumDjcErrorCodes


 

[C#]

public enumDjcErrorCodes MidiDjConsole.ProfileButtonMidiCommandGet (

string strItemName,

ref Int16 nMidiCommandPressed,

ref Int16 nMidiCommandReleased,

ref Int16 nMidiChannel,

ref Int16 nMidiDataPressed,

ref Int16 nMidiDataReleased

);


 

[C++]

public: enumDjcErrorCodes MidiDjConsole.ProfileButtonMidiCommandGet (

string strItemName,

Int16 __gc *nMidiCommandPressed,

Int16 __gc *nMidiCommandReleased,

Int16 __gc *nMidiChannel,

Int16 __gc *nMidiDataPressed,

Int16 __gc *nMidiDataReleased

);


 

Parameter

Description

 

 

strItemName

String containing the name of the push button item.

If no push button item with this specific name should be available inside the profile, the method would fail and would return an error code.

nMidiCommandPressed

Reference that, on return from the method call, will contain the number representing the MIDI command issued when the physical button is pressed. In many cases the value of this parameter is 144 (hex 90) which indicates a "Note On" MIDI command.

nMidiCommandReleased

Reference that, on return from the method call, will contain the number representing the MIDI command issued when the physical button is released: in some case this value could be identical to the value returned inside the nMidiCommandPressed parameter in which case the pressed/released status would be identified by different values of the nMidiDataPressed and nMidiDataReleased parameters below.

nMidiChannel

Reference that, on return from the method call, will contain the number representing the MIDI channel.

nMidiDataPressed

Reference that, on return from the method call, will contain the number representing the "Data" parameter of the MIDI command issued when the physical button is pressed.

The "Data" parameter is a 16 bits integer value which combines 2  bytes ("Data1" and "Data2") which usually indicate the code of the pressed button and its status (pressed/released).

Separate values of the "Data1" and "Data2" bytes can be extracted from this parameter using custom functions and/or macros.

nMidiDataReleased

Reference that, on return from the method call, will contain the number representing the "Data" parameter of the MIDI command issued when the physical button is released.

As mentioned above, the "Data" parameter is a 16 bits integer value which combines 2 bytes ("Data1" and "Data2") which usually indicate the code of the pressed button and its status (pressed/released): in some case this value could be identical to the value returned inside the nMidiDataPressed parameter in which case the pressed/released status would be identified by different values of the nMidiCommandPressed and nMidiCommandReleased parameters above.

Separate values of the "Data1" and "Data2" bytes can be extracted from this parameter using custom functions and/or macros.

 

 

Return value

 

Value

Meaning

 

 

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.