TaskDialog.AddCommandLink(TaskDialogCommandLinkId, String, String) Method

TaskDialogAddCommandLink(TaskDialogCommandLinkId, String, String) Method

Adds a CommandLink associated to the given id, displaying the indicating main and supporting content.

Namespace: Autodesk.Revit.UI
Assembly: RevitAPIUI (in RevitAPIUI.dll) Version: 25.0.0.0 (25.0.0.0)
Syntax
public void AddCommandLink(
	TaskDialogCommandLinkId id,
	string mainContent,
	string supportingContent
)
Public Sub AddCommandLink ( 
	id As TaskDialogCommandLinkId,
	mainContent As String,
	supportingContent As String
)
public:
void AddCommandLink(
	TaskDialogCommandLinkId id, 
	String^ mainContent, 
	String^ supportingContent
)
member AddCommandLink : 
        id : TaskDialogCommandLinkId * 
        mainContent : string * 
        supportingContent : string -> unit 

Parameters

id  TaskDialogCommandLinkId
The id of the CommandLink. This corresponds to the value returned by Show() when the link is chosen by the user.
mainContent  String
The main content of the CommandLink.
supportingContent  String
The main content of the CommandLink.
Exceptions
ExceptionCondition
ArgumentNullException Thrown when mainContent is .
ArgumentException Thrown when mainContent is an empty string.
ArgumentException Thrown when the mainContent contains newline characters.
Remarks

Parameter mainContent cannot contain newlines.

If the id has already been set to the task dialog, the new CommandLink definition overrides the old one.

CommandLinks will always be shown in the dialog in the order of their ids.

See Also