fl.selectTool()

Availability

Flash CS3 Professional.

Usage

fl.selectTool(toolName)

Parameters

toolName
A string that specifies the name of the tool to select. See “Description” below for information on acceptable values for this parameter.

Description

Method; selects the specified tool in the Tools panel. The acceptable default values for toolName are "arrow", "bezierSelect", "freeXform", "fillXform", "lasso", "pen", "penplus", "penminus", "penmodify", "text", "line", "rect", "oval", "rectPrimitive", "ovalPrimitive", "polystar", "pencil", "brush", "inkBottle", "bucket", "eyeDropper", "eraser", "hand", and "magnifier".

If you or a user creates custom tools, the names of those tools can also be passed as the toolName parameter. The list of tool names is located in the following file:

  • Windows Vista:

    boot drive\Users\username\Local Settings\Application Data\Adobe\Flash CS3\language\Configuration\Tools\toolConfig.xml

  • Windows XP:

    boot drive\Documents and Settings\username\Local Settings\Application Data\Adobe\Flash CS3\language\Configuration\Tools\toolConfig.xml

  • Mac OS X:

    Macintosh HD/Users/username/Library/Application Support/Adobe/Flash CS3/language/Configuration/Tools/toolConfig.xml

Example

The following example selects the Pen tool.

fl.selectTool("pen");