# Button Click Command - Tasks

The Click Command property can be associated with the following Tasks interactions:

Note:

- These interactions can also be called via a script. For more information, see the $ Functions: WebPages HMI.
- See $ Functions: Tasks for more information on the Tasks functions listed below.
- The Tasks.Task.RunBlocks $ function cannot be used with the Click Command property, but can be used with WebPage Elements Event Handler Scripts

Click Command | Description | Arguments (with Data Type) | Return Type
--- | --- | --- | ---
Tasks.TaskName.Run() | Executes the Task specified by the TaskName argument. | N/A | N/A
$Tasks.TaskName.RunBlocksFromTo("fromBlock", "toBlock") | Specifies the execution of specific Task Blocks within the Task, with a starting Task Block (specified with the fromBlockName argument) and an ending block (specified with the toBlockName argument). With this option, the starting block and all blocks between the starting block and the ending block are executed. Blocks to the left of the starting block and blocks to the right of the ending block will not be executed. | fromBlock: String, specifying the "name" of the specified Task Block to start the execution within the Task. toBlock: String, specifying the "name" of the specified Task Block at which to end the execution within the Task. | N/A
$Tasks.TaskName.RunBlocksToEnd("fromBlock") | Specifies a Task Block (with the fromBlock argument) that will be the starting point of the execution of the Task. The Task Block specified by fromBlock and all the blocks to its right will be executed. | fromBlock: String, specifying the "name" of the specified Task Block to start the execution of the Task. | N/A
Tasks.TaskName.RunSingleBlock("singleBlock") | Executes a Task Block (specified with the singleBlock argument) within the Task. | singleBlock: String, specifying the "name" of the specified Task Block within the Task to execute. | N/A