ExecuteCommandByID Method

SQL-NS

SQL-NS

ExecuteCommandByID Method

The ExecuteCommandByID method executes the command on the SQLNamespaceObject object identified by the CommandID parameter.

Applies To
SQLNamespaceObject Object
Syntax

object.ExecuteCommandByID(
CommandID,
[hWnd],
[modality])

Parts

object

Expression that evaluates to an object in the Applies To list

CommandID

Command ID

hWnd

Parent window handle

modality

Modality of the window

Prototype (C/C++)

HRESULT ExecuteCommandByID(
SQLNSCommandID CommandID,
long hwnd,
SQLNSModality modality);

Remarks

The ExecuteCommandByID method optionally provides a parent window (by default, the parent window handle specified by the Initialize method) and suggests preference in modality of the user interface. ExecuteCommandByID is the preferred method for executing commands, because it is independent of the system language of the computer where the application runs.