Hide Table of Contents
CreateCommand2 Method (IApplication)
Cmd[out]
Command

Obsolete. Superseded by IApplication::CreateCommand3 and IApplication::CreateCommand4.

.NET Syntax

Visual Basic (Declaration) 
Function CreateCommand2( _
   const dsString& ApiUuid As System.String, _
   const dsString& GlobalCmdName As System.String, _
   const dsString& LocalCmdName As System.String, _
   dsCreateCommandError_e* Error As dsCreateCommandError_e _
) As Command
C# 
Command CreateCommand2( 
   System.string ApiUuid,
   System.string GlobalCmdName,
   System.string LocalCmdName,
   out dsCreateCommandError_e Error
)
JavaScript 
CreateCommand2( 
   ApiUuid : String,
   GlobalCmdName : String,
   LocalCmdName : String
) : {
   Error : String,
   Cmd : dsCommand
}
COM native C++ 
HRESULT CreateCommand2( 
   BSTR ApiUuid,
   BSTR GlobalCmdName,
   BSTR LocalCmdName,
   dsCreateCommandError_e* Error,
   ICommand** Cmd
) 
C++ 
DSRESULT CreateCommand2( 
   const dsString& ApiUuid,
   const dsString& GlobalCmdName,
   const dsString& LocalCmdName,
   dsCreateCommandError_e* Error,
   dsCommand** Cmd
) 

Parameters

ApiUuid
UUID of the add-in or non add-in application
GlobalCmdName
Unique name for the global command, which is not displayed to the user but which can be used as input
LocalCmdName
Unique name for the localized command, which is displayed to the user and which can be used as input
Error[out]
Status of creating the command as defined in dsCreateCommandError_e
Cmd[out] or Return Value
Command

Example

 

Remarks

If either GlobalCmdName or LocalCmdName already exists, then dsCreateCommand_e.dsCreateCommandError_CommandNameExisted is returned for Error.

To see a list of existing commands:

  1. Right-click a toolbar in the user interface.
  2. Select Customize Interface.
  3. Click Commands on the left side of the dialog.
  4. Use the scroll bar to see the list of existing commands.
  5. To quickly locate a command that you've added:
    1. Type the name of the command in Find.
    2. Click the name of the command in the Name column.
    3. Examine the information at the bottom of the dialog.
 

See Also

Availability

DraftSight V1R5.0


Provide feedback on this topic

SOLIDWORKS welcomes your feedback concerning the presentation, accuracy, and thoroughness of the documentation. Use the form below to send your comments and suggestions about this topic directly to our documentation team. The documentation team cannot answer technical support questions. Click here for information about technical support.

* Required

 
*Email:  
Subject:   Feedback on Help Topics
Page:   CreateCommand2 Method (IApplication)
*Comment:  
*   I acknowledge I have read and I hereby accept the privacy policy under which my Personal Data will be used by Dassault Systèmes

Print Topic

Select the scope of content to print:

x

We have detected you are using a browser version older than Internet Explorer 7. For optimized display, we suggest upgrading your browser to Internet Explorer 7 or newer.

 Never show this message again
x

Web Help Content Version: API Help (English only) 2021 SP05

To disable Web help from within SOLIDWORKS and use local help instead, click Help > Use SOLIDWORKS Web Help.

To report problems encountered with the Web help interface and search, contact your local support representative. To provide feedback on individual help topics, use the “Feedback on this topic” link on the individual topic page.