DoCommand
Syntax:
long DoCommand (long
nCommand);
Return
Value:
Zero
if the command has been executed successfully, otherwise
non-zero.
Parameter:
nCommand Identifies the ELS-QB component command to invoke (see Remarks).
Remarks:
The
ELS-QB component supports following command
IDs:
QB_CMD_UNDO
= 1,
QB_CMD_REDO
= 2,
QB_CMD_CUT
= 3,
QB_CMD_COPY
= 4,
QB_CMD_PASTE
= 5,
QB_CMD_SELECTALL
= 6,
QB_CMD_FIND
= 7,
QB_CMD_REPLACE
= 8,
QB_CMD_PRINT
= 9,
QB_CMD_PRINT_PREVIEW
= 10,
QB_CMD_PAGE_SETUP
= 11
Call
this member function to execute the command specified by ELS-QB component command IDs.
Example:
Here is an exerpt from ELS_QBDemo project thah illustrates
the usage of DoCommand() method
of ELS-QB component.
void
CELS_QBDemoView::OnEditUndo()
{
// This will trigger the Undo command on
the SQL pane
m_QBCtrl.DoCommand(QB_CMD_UNDO);
}