# CAWT Reference 2.4.3

# ::Cawt

## Introduction

The Cawt namespace provides commands for basic automation functionality.

## Commands

#### CentiMetersToPoints [::Cawt]

Cawt, Top

Convert centimeter value into points.

CentiMetersToPoints cm

###### Parameters

cm | Floating point centimeter value to be converted to points.

###### Return value

Returns the corresponding value in points.

###### Description

Convert centimeter value into points.

See also: SetDotsPerInch InchesToPoints

#### CheckBoolean [::Cawt]

Cawt, Top

Check, if two boolean values are identical.

CheckBoolean expected value msg printCheck

###### Parameters

expected | Expected boolean value.
value | Test boolean value.
msg | Message for test case.
printCheck | (optional, default true) Print message for successful test case.

###### Return value

Returns true, if both boolean values are identical. If "printCheck" is set to true, a line prepended with "Check:" and the message supplied in "msg" is printed to standard output. If the check fails, return false and print message prepended with "Error:".

###### Description

Check, if two boolean values are identical.

See also: CheckComObjects CheckNumber CheckList CheckMatrix CheckString

#### CheckComObjects [::Cawt]

Cawt, Top

Check, if the number of COM objects fits expected value.

CheckComObjects expected msg printCheck

###### Parameters

expected | Expected number of COM objects.
msg | Message for test case.
printCheck | (optional, default true) Print message for successful test case.

###### Return value

Returns true, if the number of COM objects fits expected value. If "printCheck" is set to true, a line prepended with "Check:" and the message supplied in "msg" is printed to standard output. If the check fails, return false and print message prepended with "Error:".

###### Description

Check, if the number of COM objects fits expected value.

See also: CheckList CheckMatrix CheckBoolean CheckNumber CheckString GetNumComObjects

#### CheckList [::Cawt]

Cawt, Top

Check, if two lists are identical.

CheckList expected value msg printCheck

###### Parameters

expected | Expected list.
value | Test list.
msg | Message for test case.
printCheck | (optional, default true) Print message for successful test case.

###### Return value

Returns true, if both lists are identical. If "printCheck" is set to true, a line prepended with "Check:" and the message supplied in "msg" is printed to standard output. If the check fails, return false and print message prepended with "Error:".

###### Description

Check, if two lists are identical.

See also: CheckComObjects CheckMatrix CheckBoolean CheckNumber CheckString

#### CheckMatrix [::Cawt]

Cawt, Top

Check, if two matrices are identical.

CheckMatrix expected value msg printCheck

###### Parameters

expected | Expected matrix.
value | Test matrix.
msg | Message for test case.
printCheck | (optional, default true) Print message for successful test case.

###### Return value

Returns true, if both matrices are identical. If "printCheck" is set to true, a line prepended with "Check:" and the message supplied in "msg" is printed to standard output. If the check fails, return false and print message prepended with "Error:".

###### Description

Check, if two matrices are identical.

See also: CheckComObjects CheckList CheckBoolean CheckNumber CheckString

#### CheckNumber [::Cawt]

Cawt, Top

Check, if two numerical values are identical.

CheckNumber expected value msg printCheck

###### Parameters

expected | Expected numeric value.
value | Test numeric value.
msg | Message for test case.
printCheck | (optional, default true) Print message for successful test case.

###### Return value

Returns true, if both numeric values are identical. If "printCheck" is set to true, a line prepended with "Check:" and the message supplied in "msg" is printed to standard output. If the check fails, return false and print message prepended with "Error:".

###### Description

Check, if two numerical values are identical.

See also: CheckComObjects CheckBoolean CheckList CheckMatrix CheckString

#### CheckString [::Cawt]

Cawt, Top

Check, if two string values are identical.

CheckString expected value msg printCheck

###### Parameters

expected | Expected string value.
value | Test string value.
msg | Message for test case.
printCheck | (optional, default true) Print message for successful test case.

###### Return value

Returns true, if both string values are identical. If "printCheck" is set to true, a line prepended with "Check:" and the message supplied in "msg" is printed to standard output. If the check fails, return false and print message prepended with "Error:".

###### Description

Check, if two string values are identical.

See also: CheckComObjects CheckList CheckMatrix CheckBoolean CheckNumber

#### ClipboardToImg [::Cawt]

Cawt, Top

Copy the clipboard content into a photo image.

ClipboardToImg

###### Return value

Returns the photo image identifier.

###### Description

Copy the clipboard content into a photo image.

The photo image identifier is returned, if the clipboard content could be read correctly. Otherwise an error is thrown.

Note: The image data in the clipboard must be in BMP format. Therefore it needs the Img extension. The image must be freed by the caller (image delete), if not needed anymore.

See also: ImgToClipboard

#### ConcatFiles [::Cawt]

Cawt, Top

ConcatFiles outFile args

###### Parameters

outFile |
args | Additional options.

#### CountWords [::Cawt]

Cawt, Top

Count words contained in a string.

CountWords str args

###### Parameters

str | String to be searched.
args | List of key value pairs specifying the counting configure options and its values.

###### Return value

Returns a key-value list containing the found words and their corresponding count.

###### Description

Count words contained in a string.

Option keys:

-sortmode <string>

           Sorting mode of output list.
           Default: length. Possible values: dictionary, length.

-minlength <int>

           Only count words having more than minlength characters.
           Default: No limit.

-maxlength <int>

           Only count words having less than maxlength characters.
           Default: No limit.

-shownumbers <bool>

           If set to false, only count words which are no numbers.

Notes:

          The definition of a word is like in Tcl command "string wordend".

          This procedure can be called as a coroutine. It yields
          every 1000 bytes processed. The yield return value is the
          number of bytes already processed.
          See test script Core-04_String.tcl for an usage example.

See also: ::Word::CountWords

#### Destroy [::Cawt]

Cawt, Top

Destroy one or all COM objects.

Destroy comObj

###### Parameters

comObj | (optional, default ) The COM object to be destroyed.

###### Return value

Returns no value.

###### Description

Destroy one or all COM objects.

If "comObj" is an empty string, all existing COM objects are destroyed. Otherwise only the specified COM object is destroyed.

Note: Twapi does not clean up generated COM object identifiers, so you have to put a call to Destroy at the end of your Cawt script. For further details about COM objects and their lifetime see the Twapi documentation.

See also: PushComObjects PopComObjects

#### GetColor [::Cawt]

Cawt, Top

Convert a color representation into an Office color number.

GetColor args

###### Parameters

args | A valid color representation.

###### Description

Convert a color representation into an Office color number.

Colors can be specified in one of the following representations:

          Name: A valid Tcl color name string, ex. "black".
          Hexadecimal: A valid Tcl hexadecimal string, ex. "#00FFAA".
          RGB: 3 integer values in the range 0 .. 255.
          Office number: An integer number with encoded RGB values.

See also: GetColor GetColorNames IsHexColor IsNameColor IsRgbColor IsOfficeColor

#### GetColorNames [::Cawt]

Cawt, Top

Get all supported Tcl color names.

GetColorNames

###### Return value

Returns a sorted list of all supported Tcl color names.

###### Description

Get all supported Tcl color names.

See also: IsNameColor

#### GetComObjects [::Cawt]

Cawt, Top

Get the COM objects currently in use as a list.

GetComObjects

###### Return value

Returns the COM objects currently in use as a list.

###### Description

Get the COM objects currently in use as a list.

See also: IsComObject GetNumComObjects PrintNumComObjects Destroy

#### GetDotsPerInch [::Cawt]

Cawt, Top

Get the dots-per-inch value used for conversions.

GetDotsPerInch

###### Return value

Returns the dots-per-inch value used for conversions.

###### Description

Get the dots-per-inch value used for conversions.

See also: SetDotsPerInch

#### GetNumComObjects [::Cawt]

Cawt, Top

Get the number of COM objects currently in use.

GetNumComObjects

###### Return value

Returns the number of COM objects currently in use.

###### Description

Get the number of COM objects currently in use.

See also: IsComObject GetComObjects PrintNumComObjects Destroy

#### GetOrCreateApp [::Cawt]

Cawt, Top

Use or create an instance of an application.

GetOrCreateApp appName useExistingFirst

###### Parameters

appName | The name of the application to be create or used.
useExistingFirst | Prefer an already running application.

###### Return value

Returns the application identifier.

###### Description

Use or create an instance of an application.

Application names supported and tested with Cawt are: "Excel.Application", "PowerPoint.Application", "Word.Application", "GoogleEarth.ApplicationGE", "Matlab.Application". Note: There are higher level functions "Open" and "OpenNew" for the Cawt sub-packages.

If "useExistingFirst" is set to true, it is checked, if an application instance is already running. If true, this instance is used. If no running application is available, a new instance is started.

See also: KillApp

#### GetPkgVersion [::Cawt]

Cawt, Top

Get the version of a Cawt sub-package.

GetPkgVersion pkgName

###### Parameters

pkgName | The name of the sub-package

###### Return value

Returns the version of the sub-package as a string. If the package is not available (HavePkg == false), an empty string is returned.

###### Description

Get the version of a Cawt sub-package.

See also: HavePkg

#### GetProgramByExtension [::Cawt]

Cawt, Top

Get path to program for a given file extension.

GetProgramByExtension extension

###### Parameters

extension | The extension string (including a dot, ex. ".pdf").

###### Description

Get path to program for a given file extension.

Return the path to the program which is associated in the Windows registry with the file extension.

#### HavePkg [::Cawt]

Cawt, Top

Check, if a Cawt sub-package is available.

HavePkg pkgName

###### Parameters

pkgName | The name of the sub-package.

###### Return value

Returns true, if sub-package pkgName was loaded successfully. Otherwise returns false.

###### Description

Check, if a Cawt sub-package is available.

See also: GetPkgVersion

#### ImgToClipboard [::Cawt]

Cawt, Top

Copy a photo image into the clipboard.

ImgToClipboard phImg

###### Parameters

phImg | The photo image identifier.

###### Return value

Returns no value.

###### Description

Copy a photo image into the clipboard.

If the image could not be copied to the clipboard correctly, an error is thrown.

Note: The image data is copied to the clipboard in BMP format. Therefore it needs the Img and Base64 extensions.

See also: ClipboardToImg

#### InchesToPoints [::Cawt]

Cawt, Top

Convert inch value into points.

InchesToPoints inches

###### Parameters

inches | Floating point inch value to be converted to points.

###### Return value

Returns the corresponding value in points.

###### Description

Convert inch value into points.

See also: SetDotsPerInch CentiMetersToPoints

#### IsComObject [::Cawt]

Cawt, Top

Check, if a COM object is valid.

IsComObject comObj

###### Parameters

comObj | The COM object.

###### Return value

Returns true, if comObj is a valid object. Otherwise returns false.

###### Description

Check, if a COM object is valid.

See also: GetComObjects GetNumComObjects PrintNumComObjects

#### IsHexColor [::Cawt]

Cawt, Top

Check, if specified color is a valid Tcl hexadecimal color string.

IsHexColor color

###### Parameters

color | The Tcl color string as hexadecimal representation, ex. "#0ACCF0".

###### Return value

Returns true, if supplied string is a valid color string, otherwise false.

###### Description

Check, if specified color is a valid Tcl hexadecimal color string.

See also: GetColor GetColorNames IsNameColor IsRgbColor IsOfficeColor

#### IsNameColor [::Cawt]

Cawt, Top

Check, if specified color is a valid Tcl color name.

IsNameColor color

###### Parameters

color | The Tcl color name as a string, ex. "black".

###### Return value

Returns true, if supplied string is a valid color name, otherwise false.

###### Description

Check, if specified color is a valid Tcl color name.

See also: GetColor GetColorNames IsHexColor IsRgbColor IsOfficeColor

#### IsoDateToOutlookDate [::Cawt]

Cawt, Top

Return ISO date string as Outlook date.

IsoDateToOutlookDate isoDate

###### Parameters

isoDate | Date string in format %Y-%m-%d %H:%M:%S

###### Description

Return ISO date string as Outlook date.

Return corresponding date as floating point number representing days since 1900/01/01.

See also: OutlookDateToIsoDate IsoDateToSeconds IsoDateToXmlDate

#### IsoDateToSeconds [::Cawt]

Cawt, Top

Return ISO date string as seconds.

IsoDateToSeconds isoDate

###### Parameters

isoDate | Date string in format %Y-%m-%d %H:%M:%S

###### Description

Return ISO date string as seconds.

Return corresponding seconds as integer.

See also: SecondsToIsoDate XmlDateToSeconds OutlookDateToSeconds

#### IsoDateToXmlDate [::Cawt]

Cawt, Top

Return ISO date string as XML date string.

IsoDateToXmlDate isoDate

###### Parameters

isoDate | Date string in format %Y-%m-%d %H:%M:%S

###### Description

Return ISO date string as XML date string.

Return corresponding date as XML date string.

See also: XmlDateToIsoDate IsoDateToSeconds IsoDateToOutlookDate

#### IsOfficeColor [::Cawt]

Cawt, Top

Check, if specified color is a valid Office color number.

IsOfficeColor color

###### Parameters

color | The Office color number.

###### Return value

Returns true, if supplied string is a valid color string, otherwise false.

###### Description

Check, if specified color is a valid Office color number.

See also: GetColor GetColorNames IsHexColor IsNameColor IsRgbColor

#### IsRgbColor [::Cawt]

Cawt, Top

Check, if specified color is a valid RGB representation.

IsRgbColor r g b

###### Parameters

r | The red component of the color
g | The green component of the color
b | The blue component of the color

###### Return value

Returns true, if supplied values are in the supported range, otherwise false.

###### Description

Check, if specified color is a valid RGB representation.

The r, g and b values are specified as integers in the range 0 .. 255.

See also: GetColor GetColorNames IsHexColor IsNameColor IsOfficeColor

#### IsUnicodeFile [::Cawt]

Cawt, Top

Check, if a file is encode in Unicode.

IsUnicodeFile fileName

###### Parameters

fileName | File to check encoding.

###### Return value

Returns true, if file is encode in Unicode, otherwise false.

###### Description

Check, if a file is encode in Unicode.

Unicode encoding is detected by checking the BOM. If the first two bytes are FF FE, the file seems to be a Unicode file.

See also:

#### IsValidId [::Cawt]

Cawt, Top

Obsolete: Replaced with IsComObject in version 2.0.0

IsValidId comObj

###### Parameters

comObj |

###### Description

Obsolete: Replaced with IsComObject in version 2.0.0

#### KillApp [::Cawt]

Cawt, Top

Kill all running instances of an application.

KillApp progName

###### Parameters

progName | The application's program name, as shown in the task manager.

###### Return value

Returns no value.

###### Description

Kill all running instances of an application.

See also: GetOrCreateApp

#### OfficeColorToRgb [::Cawt]

Cawt, Top

Convert an Office color number into a RGB color list.

OfficeColorToRgb color

###### Parameters

color | The Office color number

###### Return value

Returns the color as a list of r, b and b values. The r, g and b values are returned as integers in the range 0 .. 255.

###### Description

Convert an Office color number into a RGB color list.

See also: RgbToOfficeColor GetColor

#### OutlookDateToIsoDate [::Cawt]

Cawt, Top

Return Outlook date as ISO date string.

OutlookDateToIsoDate outlookDate

###### Parameters

outlookDate | Floating point number representing days since 1900/01/01.

###### Description

Return Outlook date as ISO date string.

Return corresponding date as ISO date string.

See also: IsoDateToOutlookDate OutlookDateToSeconds

#### OutlookDateToSeconds [::Cawt]

Cawt, Top

Return Outlook date as seconds.

OutlookDateToSeconds outlookDate

###### Parameters

outlookDate | Floating point number representing days since 1900/01/01.

###### Description

Return Outlook date as seconds.

Return corresponding seconds as integer.

See also: SecondsToOutlookDate IsoDateToSeconds XmlDateToSeconds

#### PointsToCentiMeters [::Cawt]

Cawt, Top

Convert value in points into centimeters.

PointsToCentiMeters points

###### Parameters

points | Floating point value to be converted to centimeters.

###### Return value

Returns the corresponding value in centimeters.

###### Description

Convert value in points into centimeters.

See also: SetDotsPerInch InchesToPoints CentiMetersToPoints

#### PointsToInches [::Cawt]

Cawt, Top

Convert value in points into inches.

PointsToInches points

###### Parameters

points | Floating point value to be converted to inches.

###### Return value

Returns the corresponding value in inches.

###### Description

Convert value in points into inches.

See also: SetDotsPerInch CentiMetersToPoints InchesToPoints

#### PopComObjects [::Cawt]

Cawt, Top

Pop last entry from COM objects stack.

PopComObjects printStack

###### Parameters

printStack | (optional, default false) Print stack content after popping onto stdout.

###### Return value

Returns no value.

###### Description

Pop last entry from COM objects stack.

Pop last entry from COM objects stack and remove all COM objects currently in use which are not contained in the popped entry.

See also: PushComObjects

#### PrintNumComObjects [::Cawt]

Cawt, Top

Print the number of currently available COM objects to stdout.

PrintNumComObjects

###### Return value

Returns no value.

###### Description

Print the number of currently available COM objects to stdout.

See also: IsComObject GetComObjects GetNumComObjects Destroy

#### PushComObjects [::Cawt]

Cawt, Top

Push current list of COM objects onto a stack.

PushComObjects printStack

###### Parameters

printStack | (optional, default false) Print stack content after pushing onto stdout.

###### Return value

Returns no value.

###### Description

Push current list of COM objects onto a stack.

See also: PopComObjects

#### RgbToOfficeColor [::Cawt]

Cawt, Top

Convert a RGB color into an Office color number.

RgbToOfficeColor r g b

###### Parameters

r | The red component of the color
g | The green component of the color
b | The blue component of the color

###### Return value

Returns the color as an Office color integer number.

###### Description

Convert a RGB color into an Office color number.

The r, g and b values are specified as integers in the range 0 .. 255.

See also: OfficeColorToRgb GetColor

#### SecondsToIsoDate [::Cawt]

Cawt, Top

Return date in seconds as ISO date string.

SecondsToIsoDate sec

###### Parameters

sec | Date in seconds (as returned by clock seconds).

###### Description

Return date in seconds as ISO date string.

Return corresponding date as ISO date string.

See also: IsoDateToSeconds SecondsToXmlDate SecondsToOutlookDate

#### SecondsToOutlookDate [::Cawt]

Cawt, Top

Return date in seconds as Outlook date.

SecondsToOutlookDate sec

###### Parameters

sec | Date in seconds (as returned by clock seconds).

###### Description

Return date in seconds as Outlook date.

Return corresponding date as floating point number representing days since 1900/01/01.

See also: OutlookDateToSeconds SecondsToIsoDate SecondsToXmlDate

#### SecondsToXmlDate [::Cawt]

Cawt, Top

Return date in seconds as XML date string.

SecondsToXmlDate sec

###### Parameters

sec | Date in seconds (as returned by clock seconds).

###### Description

Return date in seconds as XML date string.

Return corresponding date as XML date string.

See also: XmlDateToSeconds SecondsToIsoDate SecondsToOutlookDate

#### SetDotsPerInch [::Cawt]

Cawt, Top

Set the dots-per-inch value used for conversions.

SetDotsPerInch dpi

###### Parameters

dpi | Integer dpi value.

###### Return value

Returns no value.

###### Description

Set the dots-per-inch value used for conversions.

If the dpi value is not explicitely set with this function, it's default value is 72.

See also: GetDotsPerInch

#### SplitFile [::Cawt]

Cawt, Top

SplitFile inFile maxFileSize outFilePrefix

###### Parameters

inFile |
maxFileSize | (optional, default 2048)
outFilePrefix | (optional, default )

#### TclBool [::Cawt]

Cawt, Top

Cast a value to a boolean.

TclBool val

###### Parameters

val | The value to be casted.

###### Return value

Returns true, if val is not equal to zero or true. Otherwise returns false.

###### Description

Cast a value to a boolean.

See also: TclInt TclString

#### TclInt [::Cawt]

Cawt, Top

Cast a value to an integer with boolean range.

TclInt val

###### Parameters

val | The value to be casted.

###### Return value

Returns 1, if val is not equal to zero or true. Otherwise returns 0.

###### Description

Cast a value to an integer with boolean range.

See also: TclBool TclString

#### TclString [::Cawt]

Cawt, Top

Cast a value to a string.

TclString val

###### Parameters

val | The value to be casted.

###### Return value

Returns casted string in a format usable for the COM interface.

###### Description

Cast a value to a string.

See also: TclInt TclBool

#### ValueToPoints [::Cawt]

Cawt, Top

Convert a value into points.

ValueToPoints value

###### Parameters

value | Floating point value to be converted to points.

###### Return value

Returns the corresponding value in points.

###### Description

Convert a value into points.

- If the value is followed by "i", it is interpreted as inches.
- If the value is followed by "c", it is interpreted as centimeters.
- If the value is a simple floating point number or followed by "p", it is interpreted as points, i.e. the pure value is returned.

Example:

         ValueToPoints 2c
         ValueToPoints 1.5i

See also: CentiMetersToPoints InchesToPoints

#### XmlDateToIsoDate [::Cawt]

Cawt, Top

Return XML date string as ISO date string.

XmlDateToIsoDate xmlDate

###### Parameters

xmlDate | Date string in format %Y-%m-%dT%H:%M:%S.000Z

###### Description

Return XML date string as ISO date string.

Return corresponding date as ISO date string.

See also: IsoDateToXmlDate XmlDateToSeconds

#### XmlDateToSeconds [::Cawt]

Cawt, Top

Return XML date string as seconds.

XmlDateToSeconds xmlDate

###### Parameters

xmlDate | Date string in format %Y-%m-%dT%H:%M:%S.000Z

###### Description

Return XML date string as seconds.

Return corresponding seconds as integer.

See also: SecondsToXmlDate IsoDateToSeconds OutlookDateToSeconds

# ::Earth

## Introduction

The Earth namespace provides commands to control Google Earth.

## Commands

#### IsInitialized [::Earth]

Earth, Top

Check, if a GoogleEarth instance is initialized.

IsInitialized appId

###### Parameters

appId | Identifier of the GoogleEarth instance.

###### Description

Check, if a GoogleEarth instance is initialized.

Return true or false dependent on the initialization status.

#### Open [::Earth]

Earth, Top

Open a GoogleEarth instance. Use an already running instance, if available.

Open

###### Description

Open a GoogleEarth instance. Use an already running instance, if available.

Return the identifier of the GoogleEarth application instance.

See also: OpenNew Quit

#### OpenNew [::Earth]

Earth, Top

Open a new GoogleEarth instance.

OpenNew

###### Description

Open a new GoogleEarth instance.

Return the identifier of the new GoogleEarth application instance.

See also: Open Quit

#### Quit [::Earth]

Earth, Top

Quit a GoogleEarth instance.

Quit appId

###### Parameters

appId | Identifier of the GoogleEarth instance.

###### Return value

Returns no value.

###### Description

Quit a GoogleEarth instance.

See also: Open

#### SaveImage [::Earth]

Earth, Top

Save a grey-scale image of the current view.

SaveImage appId fileName quality

###### Parameters

appId | Identifier of the GoogleEarth instance.
fileName | Name of image file.
quality | (optional, default 80) Quality of the JPEG compression in percent.

###### Return value

Returns no value.

###### Description

Save a grey-scale image of the current view.

#### SetCamera [::Earth]

Earth, Top

Set camera position and orientation.

SetCamera appId latitude longitude altitude elevation azimuth

###### Parameters

appId | Identifier of the GoogleEarth instance.
latitude | Latitude in degrees. Range [-90.0, 90.0].
longitude | Longitude in degrees. Range [-180.0, 180.0].
altitude | Altitude in meters.
elevation | Elevation angle in degrees. Range [0.0, 90.0]. 0 degrees corresponds looking to the center of the earth. 90 degrees corresponds looking to the horizon.
azimuth | Azimuth angle in degrees. Range [0.0, 360.0]. 0 degrees corresponds looking north. 90 degrees corresponds loooking east.

###### Return value

Returns no value.

###### Description

Set camera position and orientation.

# ::Excel

## Introduction

The Excel namespace provides commands to control Microsoft Excel.

## Commands

#### AddColumnChartSimple [::Excel]

Excel, Top

Add a clustered column chart to a worksheet. Simple case.

AddColumnChartSimple worksheetId numRows numCols title

###### Parameters

worksheetId | Identifier of the worksheet.
numRows | Number of rows beeing used for the chart.
numCols | Number of columns beeing used for the chart.
title | (optional, default ) String used as title of the chart.

###### Description

Add a clustered column chart to a worksheet. Simple case.

Data for the x-axis is taken from column 1, starting at row 2. Names for the lines are taken from row 1, starting at column 2. The data range for the "numCols" plots starts at (2, 2) and goes to (numRows+1, numCols+1).

Return the identifier of the added chart.

See also: CreateChart AddLineChart AddLineChartSimple AddPointChartSimple

#### AddLineChart [::Excel]

Excel, Top

Add a line chart to a worksheet. Generic case.

AddLineChart worksheetId headerRow xaxisCol startRow numRows startCol numCols title yaxisName markerSize

###### Parameters

worksheetId | Identifier of the worksheet.
headerRow | Row containing names for the lines.
xaxisCol | Data for the x-axis is taken from this column.
startRow | Starting row for data of x-axis.
numRows | Number of rows used as data of x-axis.
startCol | Column in header from which names start.
numCols | Number of columns to use for the chart.
title | (optional, default ) String used as title of the chart.
yaxisName | (optional, default Values) Name of y-axis.
markerSize | (optional, default 5) Size of marker.

###### Description

Add a line chart to a worksheet. Generic case.

The data range for the "numCols" lines starts at (startRow, startCol) and goes to (startRow+numRows-1, startCol+numCols-1).

markerSize must be between 2 and 72.

Return the identifier of the added chart.

See also: CreateChart AddLineChartSimple AddPointChartSimple AddRadarChartSimple

#### AddLineChartSimple [::Excel]

Excel, Top

Add a line chart to a worksheet. Simple case.

AddLineChartSimple worksheetId numRows numCols title yaxisName markerSize

###### Parameters

worksheetId | Identifier of the worksheet.
numRows | Number of rows used as data of x-axis.
numCols | Number of columns used as data of y-axis.
title | (optional, default ) String used as title of the chart.
yaxisName | (optional, default Values) Name of y-axis.
markerSize | (optional, default 5) Size of marker.

###### Description

Add a line chart to a worksheet. Simple case.

Data for the x-axis is taken from column 1, starting at row 2. Names for the lines are taken from row 1, starting at column 2. The data range for the "numCols" lines starts at (2, 2) and goes to (numRows+1, numCols+1).

Return the identifier of the added chart.

See also: CreateChart AddLineChart AddPointChartSimple AddRadarChartSimple

#### AddPointChartSimple [::Excel]

Excel, Top

Add a point chart to a worksheet. Simple case.

AddPointChartSimple worksheetId numRows col1 col2 title markerSize

###### Parameters

worksheetId | Identifier of the worksheet.
numRows | Number of rows beeing used for the chart.
col1 | Start column of the chart data.
col2 | End column of the chart data.
title | (optional, default ) String used as title of the chart.
markerSize | (optional, default 5) Size of the point marker.

###### Description

Add a point chart to a worksheet. Simple case.

Data for the x-axis is taken from column "col1", starting at row 2. Data for the y-axis is taken from column "col2", starting at row 2. Names for the axes are taken from row 1, columns "col1" and "col2".

Return the identifier of the added chart.

See also: CreateChart AddLineChart AddLineChartSimple AddRadarChartSimple

#### AddRadarChartSimple [::Excel]

Excel, Top

Add a radar chart to a worksheet. Simple case.

AddRadarChartSimple worksheetId numRows numCols title

###### Parameters

worksheetId | Identifier of the worksheet.
numRows | Number of rows beeing used for the chart.
numCols | Number of columns beeing used for the chart.
title | (optional, default ) String used as title of the chart.

###### Description

Add a radar chart to a worksheet. Simple case.

Data for the x-axis is taken from column 1, starting at row 2. Names for the lines are taken from row 1, starting at column 2. The data range for the "numCols" plots starts at (2, 2) and goes to (numRows+1, numCols+1).

Return the identifier of the added chart.

See also: CreateChart AddLineChart AddLineChartSimple AddPointChartSimple

#### AddSeriesTrendLine [::Excel]

Excel, Top

Add a trend line to a series.

AddSeriesTrendLine seriesId args

###### Parameters

seriesId | Identifier of the series.
args | List of key value pairs specifying the trend line configure options and its values.

###### Return value

Returns the identifier of the trend line.

###### Description

Add a trend line to a series.

Option keys:

-equation <bool>

       Set to true, if the equation for the trendline should be displayed
       on the chart (in the same data label as the R-squared value).

-rsquared <bool>

       Set to true, if the R-squared for the trendline should be displayed
       on the chart (in the same data label as the equation value).

-type <XlTrendlineType>

       Set the trend line type. Example values: xlLinear, xlPolynomial

-order <int>

       Set the order ( > 1) of a polynomal trend line.
       Only valid, if type is xlPolynomal.

See also: GetChartNumSeries GetChartSeries SetSeriesLineWidth

#### AddWorkbook [::Excel]

Excel, Top

Add a new workbook with one worksheet.

AddWorkbook appId type

###### Parameters

appId | Identifier of the Excel instance.
type | (optional, default xlWBATWorksheet) Value of enumeration type XlWBATemplate (see excelConst.tcl). Possible values: xlWBATChart, xlWBATExcel4IntlMacroSheet, xlWBATExcel4MacroSheet, xlWBATWorksheet

###### Description

Add a new workbook with one worksheet.

Return the identifier of the new workbook.

See also: OpenWorkbook Close SaveAs

#### AddWorksheet [::Excel]

Excel, Top

Add a new worksheet to the end of a workbook.

AddWorksheet workbookId name visibleType

###### Parameters

workbookId | Identifier of the workbook containing the new worksheet.
name | Name of the new worksheet.
visibleType | (optional, default xlSheetVisible) Value of enumeration type XlSheetVisibility (see excelConst.tcl). Possible values: xlSheetVisible, xlSheetHidden, xlSheetVeryHidden

###### Description

Add a new worksheet to the end of a workbook.

Return the identifier of the new worksheet.

See also: GetNumWorksheets DeleteWorksheet

#### ArrangeWindows [::Excel]

Excel, Top

Arrange the windows of an Excel application.

ArrangeWindows appId arrangeStyle

###### Parameters

appId | Identifier of the Excel instance.
arrangeStyle | (optional, default xlArrangeStyleVertical) Value of enumeration type XlArrangeStyle (see excelConst.tcl). Typical values are: xlArrangeStyleHorizontal, xlArrangeStyleTiled, xlArrangeStyleVertical

###### Return value

Returns no value.

###### Description

Arrange the windows of an Excel application.

See also: Open Visible SetWindowState

#### ChartObjToClipboard [::Excel]

Excel, Top

Copy a chart object to the clipboard.

ChartObjToClipboard chartObjId

###### Parameters

chartObjId | Identifier of the chart object.

###### Return value

Returns no value.

###### Description

Copy a chart object to the clipboard.

The chart object is stored in the clipboard as a Windows bitmap file (CF_DIB).

See also: SaveChartObjAsImage CreateChart

#### ChartToClipboard [::Excel]

Excel, Top

Obsolete: Replaced with ChartObjToClipboard in version 1.0.1

ChartToClipboard chartId

###### Parameters

chartId |

###### Description

Obsolete: Replaced with ChartObjToClipboard in version 1.0.1

#### ClipboardToMatrix [::Excel]

Excel, Top

Return the matrix values contained in the clipboard.

ClipboardToMatrix sepChar

###### Parameters

sepChar | (optional, default ;) The separation character of the clipboard matrix data.

###### Description

Return the matrix values contained in the clipboard.

The clipboard data must be in CSV format with sepChar as separation character. See SetMatrixValues for the description of a matrix representation.

See also: ClipboardToWorksheet MatrixToClipboard

#### ClipboardToWorksheet [::Excel]

Excel, Top

Insert the matrix values contained in the clipboard into a worksheet.

ClipboardToWorksheet worksheetId startRow startCol sepChar

###### Parameters

worksheetId | Identifier of the worksheet.
startRow | (optional, default 1) Row number. Row numbering starts with 1.
startCol | (optional, default 1) Column number. Column numbering starts with 1.
sepChar | (optional, default ;) The separation character of the clipboard matrix data.

###### Return value

Returns no value.

###### Description

Insert the matrix values contained in the clipboard into a worksheet.

The insertion of the matrix data starts at cell "startRow,startCol". The clipboard data must be in CSV format with sepChar as separation character. See SetMatrixValues for the description of a matrix representation.

See also: ClipboardToMatrix WorksheetToClipboard

#### Close [::Excel]

Excel, Top

Close a workbook without saving changes.

Close workbookId

###### Parameters

workbookId | Identifier of the workbook.

###### Return value

Returns no value.

###### Description

Close a workbook without saving changes.

Use the SaveAs method before closing, if you want to save changes.

See also: SaveAs OpenWorkbook

#### ColumnCharToInt [::Excel]

Excel, Top

Return an Excel column string as a column number.

ColumnCharToInt colChar

###### Parameters

colChar | Column string.

###### Description

Return an Excel column string as a column number.

Example:

        [Excel ColumnCharToInt A] returns 1.
        [Excel ColumnCharToInt Z] returns 26.

See also: GetColumnNumber ColumnIntToChar

#### ColumnIntToChar [::Excel]

Excel, Top

Return a column number as an Excel column string.

ColumnIntToChar col

###### Parameters

col | Column number.

###### Description

Return a column number as an Excel column string.

Example:

        [Excel ColumnIntToChar 1]  returns "A".
        [Excel ColumnIntToChar 26] returns "Z".

See also: ColumnCharToInt

#### CopyColumn [::Excel]

Excel, Top

Copy the contents of a column into another column.

CopyColumn fromWorksheetId fromCol toWorksheetId toCol fromRow toRow pasteType

###### Parameters

fromWorksheetId | Identifier of the source worksheet.
fromCol | Source column number. Column numbering starts with 1.
toWorksheetId | Identifier of the destination worksheet.
toCol | Destination column number. Column numbering starts with 1.
fromRow | (optional, default 1) Start row of source column.
toRow | (optional, default 1) Start row of destination column.
pasteType | (optional, default xlPasteAll) Value of enumeration type XlPasteType (see excelConst.tcl). Typical values are: xlPasteAll, xlPasteAllExceptBorders, xlPasteValues.

###### Return value

Returns no value.

###### Description

Copy the contents of a column into another column.

Note, that the contents of the destination column are overwritten.

See also: CopyRange CopyWorksheet

#### CopyRange [::Excel]

Excel, Top

Copy the contents of a cell range into another cell range.

CopyRange fromRangeId toRangeId pasteType

###### Parameters

fromRangeId | Identifier of the source range.
toRangeId | Identifier of the destination range.
pasteType | (optional, default xlPasteAll) Value of enumeration type XlPasteType (see excelConst.tcl). Typical values are: xlPasteAll, xlPasteAllExceptBorders, xlPasteValues.

###### Return value

Returns no value.

###### Description

Copy the contents of a cell range into another cell range.

Note, that the contents of the destination range are overwritten.

See also: SelectAll CopyWorksheet CopyColumn

#### CopyWorksheet [::Excel]

Excel, Top

Copy the contents of a worksheet into another worksheet.

CopyWorksheet fromWorksheetId toWorksheetId

###### Parameters

fromWorksheetId | Identifier of the source worksheet.
toWorksheetId | Identifier of the destination worksheet.

###### Return value

Returns no value.

###### Description

Copy the contents of a worksheet into another worksheet.

Note, that the contents of worksheet toWorksheetId are overwritten.

See also: SelectAll CopyWorksheetBefore CopyWorksheetAfter AddWorksheet

#### CopyWorksheetAfter [::Excel]

Excel, Top

Copy the contents of a worksheet after another worksheet.

CopyWorksheetAfter fromWorksheetId afterWorksheetId worksheetName

###### Parameters

fromWorksheetId | Identifier of the source worksheet.
afterWorksheetId | Identifier of the destination worksheet.
worksheetName | (optional, default ) Name of the new worksheet. If no name is specified, or an empty string, the naming is done by Excel.

###### Description

Copy the contents of a worksheet after another worksheet.

Instead of using the identifier of afterWorksheetId, it is also possible to use the numeric index or the special word "end" for specifying the last worksheet.

Note, that a new worksheet is generated after worksheet afterWorksheetId, while CopyWorksheet overwrites the contents of an existing worksheet. The new worksheet is set as the active sheet.

Return the identifier of the new worksheet.

See also: SelectAll CopyWorksheet CopyWorksheetBefore AddWorksheet

#### CopyWorksheetBefore [::Excel]

Excel, Top

Copy the contents of a worksheet before another worksheet.

CopyWorksheetBefore fromWorksheetId beforeWorksheetId worksheetName

###### Parameters

fromWorksheetId | Identifier of the source worksheet.
beforeWorksheetId | Identifier of the destination worksheet.
worksheetName | (optional, default ) Name of the new worksheet. If no name is specified, or an empty string, the naming is done by Excel.

###### Description

Copy the contents of a worksheet before another worksheet.

Instead of using the identifier of afterWorksheetId, it is also possible to use the numeric index or the special word "end" for specifying the last worksheet.

Note, that a new worksheet is generated before worksheet beforeWorksheetId, while CopyWorksheet overwrites the contents of an existing worksheet. The new worksheet is set as the active sheet.

Return the identifier of the new worksheet.

See also: SelectAll CopyWorksheet CopyWorksheetAfter AddWorksheet

#### CreateChart [::Excel]

Excel, Top

Create a new empty chart in a worksheet.

CreateChart worksheetId chartType

###### Parameters

worksheetId | Identifier of the worksheet.
chartType | Value of enumeration type XlChartType (see excelConst.tcl).

###### Description

Create a new empty chart in a worksheet.

Return the identifier of the new chart.

See also: PlaceChart AddLineChart AddLineChartSimple AddPointChartSimple AddRadarChartSimple

#### CreateRangeString [::Excel]

Excel, Top

Create a range string in A1 notation.

CreateRangeString args

###### Parameters

args | List of quadruples specifying cell ranges.

###### Description

Create a range string in A1 notation.

The first two elements of each quadruple represent the row and column indices of the top-left cell of each range. The last two elements of each quadruple represent the row and column indices of the bottom-right cell of the range.

Example: CreateRangeString 1 1 2 3 4 2 6 3 returns "A1:C2;B4:C6"

Return range string in A1 notation.

See also: SelectRangeByIndex SelectRangeByString

#### CsvRowToList [::Excel]

Excel, Top

Return a CSV encoded row as a list of column values.

CsvRowToList rowStr

###### Parameters

rowStr | CSV encoded row as string.

###### Description

Return a CSV encoded row as a list of column values.

See also: ListToCsvRow

#### CsvStringToMatrix [::Excel]

Excel, Top

Return a matrix from a CSV encoded table string.

CsvStringToMatrix csvString

###### Parameters

csvString | CSV encoded table as string.

###### Description

Return a matrix from a CSV encoded table string.

See also: MatrixToCsvString CsvRowToList

#### DeleteColumn [::Excel]

Excel, Top

Delete a column.

DeleteColumn worksheetId col

###### Parameters

worksheetId | Identifier of the worksheet.
col | Column number. Column numbering starts with 1.

###### Return value

Returns no value.

###### Description

Delete a column.

The specified column is deleted.

See also: InsertColumn DuplicateColumn HideColumn DeleteRow DeleteWorksheet

#### DeleteRow [::Excel]

Excel, Top

Delete a row.

DeleteRow worksheetId row

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.

###### Return value

Returns no value.

###### Description

Delete a row.

The specified row is deleted.

See also: InsertRow DuplicateRow HideRow DeleteColumn DeleteWorksheet

#### DeleteWorksheet [::Excel]

Excel, Top

Delete a worksheet.

DeleteWorksheet workbookId worksheetId

###### Parameters

workbookId | Identifier of the workbook containing the worksheet.
worksheetId | Identifier of the worksheet to delete.

###### Return value

Returns no value.

###### Description

Delete a worksheet.

If the number of worksheets before deletion is 1, an error is thrown.

See also: DeleteWorksheetByIndex GetWorksheetIdByIndex AddWorksheet

#### DeleteWorksheetByIndex [::Excel]

Excel, Top

Delete a worksheet identified by its index.

DeleteWorksheetByIndex workbookId index

###### Parameters

workbookId | Identifier of the workbook containing the worksheet.
index | Index of the worksheet to delete.

###### Return value

Returns no value.

###### Description

Delete a worksheet identified by its index.

The left-most worksheet has index 1. If the index is out of bounds, or the number of worksheets before deletion is 1, an error is thrown.

See also: GetNumWorksheets GetWorksheetIdByIndex AddWorksheet

#### DiffExcelFiles [::Excel]

Excel, Top

Compare two Excel files visually.

DiffExcelFiles excelBaseFile excelNewFile args

###### Parameters

excelBaseFile | Name of the base Excel file.
excelNewFile | Name of the new Excel file.
args | Mark color.

###### Return value

Returns the identifier of the new Excel application instance.

###### Description

Compare two Excel files visually.

The two Excel files are opened in read-only mode and the cells, which are different in the two Excel files are set to the mark color. As Excel does not allow to load two files with identical names (even from different directories), in that case the excelBaseFile is copied into a temporary directory and renamed.

The algorithm used is identical to the Excel diff script used in Tortoise SVN.

Color value may be specified in a format acceptable by procedure ::Cawt::GetColor, i.e. color name, hexadecimal string, Office color number or a list of 3 integer RGB values. If no mark color is specified, it is set to red.

See also: OpenNew ::Cawt::GetColor

#### DuplicateColumn [::Excel]

Excel, Top

Duplicate a column.

DuplicateColumn worksheetId col

###### Parameters

worksheetId | Identifier of the worksheet.
col | Column number. Column numbering starts with 1.

###### Return value

Returns no value.

###### Description

Duplicate a column.

The specified column is duplicated with formatting and formulas.

See also: InsertColumn DeleteColumn HideColumn DuplicateRow

#### DuplicateRow [::Excel]

Excel, Top

Duplicate a row.

DuplicateRow worksheetId row

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.

###### Return value

Returns no value.

###### Description

Duplicate a row.

The specified row is duplicated with formatting and formulas.

See also: InsertRow DeleteRow HideRow DuplicateColumn

#### ExcelFileToHtmlFile [::Excel]

Excel, Top

Convert an Excel file to a HTML table file.

ExcelFileToHtmlFile excelFileName htmlFileName args

###### Parameters

excelFileName | Name of the Excel input file.
htmlFileName | Name of the HTML output file.
args | List of key value pairs specifying options and its values.

###### Return value

Returns the Excel application identifier, if -quit is false. Otherwise no return value.

###### Description

Convert an Excel file to a HTML table file.

Option keys: -worksheet

          Set the worksheet name or index to convert.
          Default value: 0

-quit

          true: Quit the Excel instance after generation of output file.
          false: Leave the Excel instance open after generation of output file.
          Default value: true

-target

          true: Generate a target attribute for hyperlinks.
          false: No target attribute for hyperlinks, i.e. link opens in same tab.
          Default value: true

Note, that the Excel Workbook is opened in read-only mode.

See also: WorksheetToHtmlFile WriteHtmlFile MediaWikiFileToExcelFile WikitFileToExcelFile

#### ExcelFileToMatlabFile [::Excel]

Excel, Top

Convert an Excel file to a Matlab table file.

ExcelFileToMatlabFile excelFileName matFileName worksheetNameOrIndex useHeader quitExcel

###### Parameters

excelFileName | Name of the Excel input file.
matFileName | Name of the Matlab output file.
worksheetNameOrIndex | (optional, default 0) Worksheet name or index to convert.
useHeader | (optional, default true) true: Use the first row of the worksheet as the header of the Matlab file. false: Do not generate a Matlab file header. All worksheet cells are interpreted as data.
quitExcel | (optional, default true) true: Quit the Excel instance after generation of output file. false: Leave the Excel instance open after generation of output file.

###### Return value

Returns the Excel application identifier, if quitExcel is false. Otherwise no return value.

###### Description

Convert an Excel file to a Matlab table file.

Note, that the Excel Workbook is opened in read-only mode.

See also: MatlabFileToWorksheet MatlabFileToExcelFile ReadMatlabFile WriteMatlabFile

#### ExcelFileToMediaWikiFile [::Excel]

Excel, Top

Convert an Excel file to a MediaWiki table file.

ExcelFileToMediaWikiFile excelFileName wikiFileName worksheetNameOrIndex useHeader quitExcel

###### Parameters

excelFileName | Name of the Excel input file.
wikiFileName | Name of the MediaWiki output file.
worksheetNameOrIndex | (optional, default 0) Worksheet name or index to convert.
useHeader | (optional, default true) true: Use the first row of the worksheet as the header of the MediaWiki table. false: Do not generate a MediaWiki table header. All worksheet cells are interpreted as data.
quitExcel | (optional, default true) true: Quit the Excel instance after generation of output file. false: Leave the Excel instance open after generation of output file.

###### Return value

Returns the Excel application identifier, if quitExcel is false. Otherwise no return value.

###### Description

Convert an Excel file to a MediaWiki table file.

Note, that the Excel Workbook is opened in read-only mode.

See also: MediaWikiFileToWorksheet MediaWikiFileToExcelFile ReadMediaWikiFile WriteMediaWikiFile WikitFileToExcelFile

#### ExcelFileToRawImageFile [::Excel]

Excel, Top

Convert an Excel file to a raw photo image file.

ExcelFileToRawImageFile excelFileName rawFileName worksheetNameOrIndex useHeader quitExcel pixelType

###### Parameters

excelFileName | Name of the Excel input file.
rawFileName | Name of the image output file.
worksheetNameOrIndex | (optional, default 0) Worksheet name or index to convert.
useHeader | (optional, default true) true: Use the first row of the worksheet as the header of the raw image file. false: Do not generate a raw image file header. All worksheet cells are interpreted as data.
quitExcel | (optional, default true) true: Quit the Excel instance after generation of output file. false: Leave the Excel instance open after generation of output file.
pixelType | (optional, default float) Pixel type (byte, short, float).

###### Description

Convert an Excel file to a raw photo image file.

Note, that the Excel Workbook is opened in read-only mode.

Return the Excel application identifier, if quitExcel is false. Otherwise no return value.

See also: RawImageFileToWorksheet RawImageFileToExcelFile ReadRawImageFile WriteRawImageFile

#### ExcelFileToWikitFile [::Excel]

Excel, Top

Convert an Excel file to a Wikit table file.

ExcelFileToWikitFile excelFileName wikiFileName worksheetNameOrIndex useHeader quitExcel

###### Parameters

excelFileName | Name of the Excel input file.
wikiFileName | Name of the Wikit output file.
worksheetNameOrIndex | (optional, default 0) Worksheet name or index to convert.
useHeader | (optional, default true) true: Use the first row of the worksheet as the header of the Wikit table. false: Do not generate a Wikit table header. All worksheet cells are interpreted as data.
quitExcel | (optional, default true) true: Quit the Excel instance after generation of output file. false: Leave the Excel instance open after generation of output file.

###### Description

Convert an Excel file to a Wikit table file.

Note, that the Excel Workbook is opened in read-only mode.

Return the Excel application identifier, if quitExcel is false. Otherwise no return value.

See also: WikitFileToWorksheet WikitFileToExcelFile ReadWikitFile WriteWikitFile MediaWikiFileToExcelFile

#### FormatHeaderRow [::Excel]

Excel, Top

Format a row as a header row.

FormatHeaderRow worksheetId row startCol endCol

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.
startCol | Column number of formatting start. Column numbering starts with 1.
endCol | Column number of formatting end. Column numbering starts with 1.

###### Return value

Returns no value.

###### Description

Format a row as a header row.

The cell values of a header are formatted as bold text with both vertical and horizontal centered alignment.

See also: SetHeaderRow

#### FreezePanes [::Excel]

Excel, Top

Freeze a range in a worksheet identified by its row/column index.

FreezePanes worksheetId row col onOff

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.
onOff | (optional, default true) true: Freeze the range. false: Unfreeze the range.

###### Description

Freeze a range in a worksheet identified by its row/column index.

The rows and columns with indices lower than the specified values are freezed for scrolling. If a row or a column should not be freezed, a value of zero for the corresponding parameter should be given.

See also: SelectCellByIndex

#### GetActiveWorkbook [::Excel]

Excel, Top

Return the active workbook of an application.

GetActiveWorkbook appId

###### Parameters

appId | Identifier of the Excel instance.

###### Description

Return the active workbook of an application.

Return the identifier of the active workbook.

See also: OpenWorkbook

#### GetCellComment [::Excel]

Excel, Top

Return the comment text of a cell.

GetCellComment worksheetId row col

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.

###### Description

Return the comment text of a cell.

If the cell does not contain a comment, an empty string is returned.

See also: SetRangeComment SetCommentDisplayMode SetCommentSize GetCellValue

#### GetCellIdByIndex [::Excel]

Excel, Top

Return a cell of a worksheet.

GetCellIdByIndex worksheetId row col

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.

###### Description

Return a cell of a worksheet.

Return the cell identifier of the cell with index (row, col).

See also: SelectCellByIndex AddWorksheet

#### GetCellRange [::Excel]

Excel, Top

Return a numeric cell range as an Excel range string in A1 notation.

GetCellRange row1 col1 row2 col2

###### Parameters

row1 | Row number of upper-left corner of the cell range.
col1 | Column number of upper-left corner of the cell range.
row2 | Row number of lower-right corner of the cell range.
col2 | Column number of lower-right corner of the cell range.

###### Description

Return a numeric cell range as an Excel range string in A1 notation.

Example:

        [GetCellRange 1 2  5 7] returns string "B1:G5".

See also: GetColumnRange

#### GetCellsId [::Excel]

Excel, Top

Return the cells identifier of a worksheet.

GetCellsId worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Description

Return the cells identifier of a worksheet.

Return the range of all cells from a worksheet. This corresponds to the method Cells() of the Worksheet object.

#### GetCellValue [::Excel]

Excel, Top

Return the value of a cell.

GetCellValue worksheetId row col fmt

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.
fmt | (optional, default text) Format of the cell. Possible values: "text", "int", "real".

###### Description

Return the value of a cell.

Depending on the format the value of the cell is returned as a string, integer number or a floating-point number. If the value could not be retrieved, an error is thrown.

See also: SetCellValue ColumnCharToInt

#### GetChartNumSeries [::Excel]

Excel, Top

Return the number of series of a chart.

GetChartNumSeries chartId

###### Parameters

chartId | Identifier of the chart.

###### Description

Return the number of series of a chart.

See also: GetChartSeries CreateChart

#### GetChartSeries [::Excel]

Excel, Top

Get a specific series of a chart.

GetChartSeries chartId index

###### Parameters

chartId | Identifier of the chart.
index | Index of the series. Index numbering starts with 1.

###### Description

Get a specific series of a chart.

Return the series identifier.

See also: GetChartNumSeries CreateChart SetSeriesLineWidth

#### GetColumnNumber [::Excel]

Excel, Top

Return an Excel column string or number as a column number.

GetColumnNumber colStrOrInt

###### Parameters

colStrOrInt | Column string.

###### Description

Return an Excel column string or number as a column number.

See also: ColumnCharToInt

#### GetColumnRange [::Excel]

Excel, Top

Return a numeric column range as an Excel range string.

GetColumnRange col1 col2

###### Parameters

col1 | Column number of the left-most column.
col2 | Column number of the right-most column.

###### Description

Return a numeric column range as an Excel range string.

Example:

        [GetColumnRange 2 7] returns string "B:G".

See also: GetCellRange

#### GetColumnValues [::Excel]

Excel, Top

Return column values as a Tcl list.

GetColumnValues worksheetId col startRow numVals

###### Parameters

worksheetId | Identifier of the worksheet.
col | Column number. Column numbering starts with 1.
startRow | (optional, default 0) Row number of start. Row numbering starts with 1. Negative or zero: Start at first available row.
numVals | (optional, default 0) Negative or zero: All available column values are returned. Positive: Only numVals values of the column are returned.

###### Description

Return column values as a Tcl list.

Note, that the functionality of this procedure has changed slightly with CAWT versions greater than 1.0.5: If "startRow" is not specified, "startRow" is not set to 1, but it is set to the first available row. Possible incompatibility.

Return the values of the specified column or column range as a Tcl list.

See also: SetColumnValues GetRowValues GetCellValue ColumnCharToInt GetFirstUsedRow

#### GetCsvSeparatorChar [::Excel]

Excel, Top

Return the column separator character.

GetCsvSeparatorChar

###### Description

Return the column separator character.

#### GetCurrencyFormat [::Excel]

Excel, Top

Return an Excel number format string for currencies.

GetCurrencyFormat appId currency pre post floatSep

###### Parameters

appId | Identifier of the Excel instance.
currency | String identifying the currency symbol.
pre | (optional, default 0) Number of digits before the decimal point.
post | (optional, default 00) Number of digits after the decimal point.
floatSep | (optional, default ) Specify the floating point separator character.

###### Description

Return an Excel number format string for currencies.

The currency may be specified either by using one of the predefined names (Dollar, Euro, Pound, Yen, DM) or by specifying an Unicode character.

Example:

         [GetCurrencyFormat "\u20B0" "0" "00"] will return the Excel format string
         to show floating point values with 2 digits after the decimal point
         and a German Penny Sign as currency symbol.

See also: SetRangeFormat GetNumberFormat

#### GetDecimalSeparator [::Excel]

Excel, Top

Return the decimal separator used by Excel.

GetDecimalSeparator appId

###### Parameters

appId | Identifier of the Excel instance.

###### Description

Return the decimal separator used by Excel.

See also: GetVersion GetThousandsSeparator

#### GetEnum [::Excel]

Excel, Top

Get numeric value of an enumeration.

GetEnum enumOrString

###### Parameters

enumOrString | Enumeration name

###### Return value

Returns the numeric value of an enumeration.

###### Description

Get numeric value of an enumeration.

See also: GetEnumName GetEnumTypes GetEnumVal GetEnumNames

#### GetEnumName [::Excel]

Excel, Top

Get name of a given enumeration type and numeric value.

GetEnumName enumType enumVal

###### Parameters

enumType | Enumeration type
enumVal | Enumeration numeric value.

###### Return value

Returns a list of names of a given enumeration type.

###### Description

Get name of a given enumeration type and numeric value.

See also: GetEnumNames GetEnumTypes GetEnumVal GetEnum

#### GetEnumNames [::Excel]

Excel, Top

Get names of a given enumeration type.

GetEnumNames enumType

###### Parameters

enumType | Enumeration type

###### Return value

Returns a list of names of a given enumeration type.

###### Description

Get names of a given enumeration type.

See also: GetEnumName GetEnumTypes GetEnumVal GetEnum

#### GetEnumTypes [::Excel]

Excel, Top

Get available enumeration types.

GetEnumTypes

###### Return value

Returns a list of available enumeration types.

###### Description

Get available enumeration types.

See also: GetEnumName GetEnumNames GetEnumVal GetEnum

#### GetEnumVal [::Excel]

Excel, Top

Get numeric value of an enumeration name.

GetEnumVal enumName

###### Parameters

enumName | Enumeration name

###### Return value

Returns the numeric value of an enumeration name.

###### Description

Get numeric value of an enumeration name.

See also: GetEnumName GetEnumTypes GetEnumNames GetEnum

#### GetExtString [::Excel]

Excel, Top

Return the default extension of an Excel file.

GetExtString appId

###### Parameters

appId | Identifier of the Excel instance.

###### Return value

Returns the default extension of an Excel file.

###### Description

Return the default extension of an Excel file.

Starting with Excel 12 (2007) this is the string ".xlsx". In previous versions it was ".xls".

See also: ::Office::GetOfficeType

#### GetFirstUsedColumn [::Excel]

Excel, Top

Return the index of the first used column of a worksheet.

GetFirstUsedColumn worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Description

Return the index of the first used column of a worksheet.

See also: GetNumColumns GetNumUsedColumns GetLastUsedColumn GetNumUsedRows

#### GetFirstUsedRow [::Excel]

Excel, Top

Return the index of the first used row of a worksheet.

GetFirstUsedRow worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Description

Return the index of the first used row of a worksheet.

See also: GetNumRows GetNumUsedRows GetLastUsedRow GetNumUsedColumns

#### GetFloatSeparator [::Excel]

Excel, Top

Obsolete: Replaced with GetDecimalSeparator in version 2.1.0

GetFloatSeparator

###### Description

Obsolete: Replaced with GetDecimalSeparator in version 2.1.0

Return the decimal separator used by Excel.

Only valid, after a call of Open or OpenNew. Note, that this procedure has been superseeded with GetDecimalSeparator in version 2.1.0. Only use it, if using an Excel version older than 2007.

See also: GetVersion GetDecimalSeparator GetThousandsSeparator

#### GetHiddenColumns [::Excel]

Excel, Top

Return the hidden columns of a worksheet.

GetHiddenColumns worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Description

Return the hidden columns of a worksheet.

Return the hidden columns as a list of column numbers. If no columns are hidden, an empty list is returned. Column numbering starts with 1.

See also: HideColumn GetHiddenRows ColumnCharToInt

#### GetHiddenRows [::Excel]

Excel, Top

Return the hidden rows of a worksheet.

GetHiddenRows worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Description

Return the hidden rows of a worksheet.

Return the hidden rows as a list of row numbers. If no rows are hidden, an empty list is returned. Row numbering starts with 1.

See also: HideRow GetHiddenColumns ColumnCharToInt

#### GetLangNumberFormat [::Excel]

Excel, Top

Obsolete: Replaced with GetNumberFormat in version 2.1.0

GetLangNumberFormat pre post floatSep

###### Parameters

pre |
post |
floatSep | (optional, default )

###### Description

Obsolete: Replaced with GetNumberFormat in version 2.1.0

Return an Excel number format string.

pre | Number of digits before the decimal point.
post | Number of digits after the decimal point.
floatSep | Specify the floating point separator character.

The number of digits is specified as a string containing as many zeros as wanted digits. If no floating point separator is specified or the empty string, the floating point separator of Excel is used.

Example:

        [GetLangNumberFormat "0" "0000"] will return the Excel format string
        to show floating point values with 4 digits after the decimal point.

See also: SetRangeFormat

#### GetLastUsedColumn [::Excel]

Excel, Top

Return the index of the last used column of a worksheet.

GetLastUsedColumn worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Description

Return the index of the last used column of a worksheet.

See also: GetNumColumns GetNumUsedColumns GetFirstUsedColumn GetNumUsedRows

#### GetLastUsedRow [::Excel]

Excel, Top

Return the index of the last used row of a worksheet.

GetLastUsedRow worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Description

Return the index of the last used row of a worksheet.

See also: GetNumRows GetNumUsedRows GetFirstUsedRow GetNumUsedColumns

#### GetMatrixValues [::Excel]

Excel, Top

Return worksheet table values as a matrix.

GetMatrixValues worksheetId row1 col1 row2 col2

###### Parameters

worksheetId | Identifier of the worksheet.
row1 | Row number of upper-left corner of the cell range.
col1 | Column number of upper-left corner of the cell range.
row2 | Row number of lower-right corner of the cell range.
col2 | Column number of lower-right corner of the cell range.

###### Description

Return worksheet table values as a matrix.

See also: SetMatrixValues GetRowValues GetColumnValues

#### GetMaxColumns [::Excel]

Excel, Top

Return the maximum number of columns of an Excel table.

GetMaxColumns appId

###### Parameters

appId | Identifier of the Excel instance.

###### Description

Return the maximum number of columns of an Excel table.

See also: GetNumColumns

#### GetMaxRows [::Excel]

Excel, Top

Return the maximum number of rows of an Excel table.

GetMaxRows appId

###### Parameters

appId | Identifier of the Excel instance.

###### Description

Return the maximum number of rows of an Excel table.

See also: GetNumRows

#### GetNamedRange [::Excel]

Excel, Top

Get the identifier of a named range.

GetNamedRange objId rangeName

###### Parameters

objId | Identifier of a workbook or worksheet.
rangeName | Name of range to get.

###### Description

Get the identifier of a named range.

Return the range identifier of the named range.

See also: SelectRangeByIndex GetNamedRangeNames SetNamedRange

#### GetNamedRangeNames [::Excel]

Excel, Top

Get the names of named ranges.

GetNamedRangeNames objId

###### Parameters

objId | Identifier of a workbook or worksheet.

###### Return value

Returns a sorted list of all names.

###### Description

Get the names of named ranges.

See also: GetNamedRange SetNamedRange

#### GetNumberFormat [::Excel]

Excel, Top

Return an Excel number format string.

GetNumberFormat appId pre post floatSep

###### Parameters

appId | Identifier of the Excel instance.
pre | Number of digits before the decimal point.
post | Number of digits after the decimal point.
floatSep | (optional, default ) Specify the floating point separator character.

###### Description

Return an Excel number format string.

The number of digits is specified as a string containing as many zeros as wanted digits. If no floating point separator is specified or the empty string, the floating point separator of Excel is used.

Example:

        [GetNumberFormat "0" "0000"] will return the Excel format string
        to show floating point values with 4 digits after the decimal point.

See also: SetRangeFormat GetCurrencyFormat

#### GetNumColumns [::Excel]

Excel, Top

Return the number of columns of a cell range.

GetNumColumns rangeId

###### Parameters

rangeId | Identifier of a range, cells collection or a worksheet.

###### Description

Return the number of columns of a cell range.

If specifying a worksheetId or cellsId, the maximum number of columns of a worksheet will be returned. The maximum number of columns is 256 for Excel versions before 2007. Since 2007 the maximum number of columns is 16.384.

See also: GetMaxColumns GetNumUsedColumns GetFirstUsedColumn GetLastUsedColumn GetNumRows

#### GetNumRows [::Excel]

Excel, Top

Return the number of rows of a cell range.

GetNumRows rangeId

###### Parameters

rangeId | Identifier of a range, cells collection or a worksheet.

###### Description

Return the number of rows of a cell range.

If specifying a worksheetId or cellsId, the maximum number of rows of a worksheet will be returned. The maximum number of rows is 65.536 for Excel versions before 2007. Since 2007 the maximum number of rows is 1.048.576.

See also: GetMaxRows GetNumUsedRows GetFirstUsedRow GetLastUsedRow GetNumColumns

#### GetNumUsedColumns [::Excel]

Excel, Top

Return the number of used columns of a worksheet.

GetNumUsedColumns worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Description

Return the number of used columns of a worksheet.

Note, that this procedure returns 1, even if the worksheet is empty. Use IsWorksheetEmpty to determine, if a worksheet is totally empty.

See also: GetNumColumns GetFirstUsedColumn GetLastUsedColumn GetNumUsedRows

#### GetNumUsedRows [::Excel]

Excel, Top

Return the number of used rows of a worksheet.

GetNumUsedRows worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Description

Return the number of used rows of a worksheet.

Note, that this procedure returns 1, even if the worksheet is empty. Use IsWorksheetEmpty to determine, if a worksheet is totally empty.

See also: GetNumRows GetFirstUsedRow GetLastUsedRow GetNumUsedColumns

#### GetNumWorksheets [::Excel]

Excel, Top

Return the number of worksheets in a workbook.

GetNumWorksheets workbookId

###### Parameters

workbookId | Identifier of the workbook.

###### Description

Return the number of worksheets in a workbook.

See also: AddWorksheet OpenWorkbook

#### GetRangeAsIndex [::Excel]

Excel, Top

Get address of a cell range as list of row/column indices.

GetRangeAsIndex rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Get address of a cell range as list of row/column indices.

Return address of a cell range as a 2 or 4 element list of integers:

If the range represents a single cell, the list consists of 2 elements, representing the row and column index of the cell.

If the range represents more than one cell, the list consists of 4 elements. The first two elements represent the row and column indices of the top-left cell of the range. The last two elements represent the row and column indices of the bottom-right cell of the range.

See also: SelectRangeByIndex GetCellRange

#### GetRangeAsString [::Excel]

Excel, Top

Get address of a cell range as Excel range string in A1 notation.

GetRangeAsString rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Get address of a cell range as Excel range string in A1 notation.

Return address of a cell range as Excel range string in A1 notation.

See also: SelectRangeByString GetCellRange

#### GetRangeCharacters [::Excel]

Excel, Top

Return characters of a cell range.

GetRangeCharacters rangeId start length

###### Parameters

rangeId | Identifier of the cell range.
start | (optional, default 1) Start of the character range.
length | (optional, default -1) The number of characters after start.

###### Description

Return characters of a cell range.

Return all or a range of characters of a cell range. If no optional parameters are specified, all characters of the cell range are returned.

See also: SelectRangeByIndex SelectRangeByString

#### GetRangeFillColor [::Excel]

Excel, Top

Get the fill color of a cell range.

GetRangeFillColor rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Return value

Returns the fill color as a list of r, b and b values.

###### Description

Get the fill color of a cell range.

The r, g and b values are returned as integers in the range [0, 255].

See also: SetRangeFillColor ::Cawt::OfficeColorToRgb SelectRangeByIndex SelectRangeByString

#### GetRangeFontBold [::Excel]

Excel, Top

Get the bold font style of a cell range.

GetRangeFontBold rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Get the bold font style of a cell range.

Return true, if the font in specified cell range has the bold flag set.

See also: SetRangeFontBold SelectRangeByIndex

#### GetRangeFontItalic [::Excel]

Excel, Top

Get the italic font style of a cell range.

GetRangeFontItalic rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Get the italic font style of a cell range.

Return true, if the font in specified cell range has the italic flag set.

See also: SetRangeFontItalic SelectRangeByIndex

#### GetRangeFontName [::Excel]

Excel, Top

Get the font name of a cell or character range.

GetRangeFontName rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Get the font name of a cell or character range.

Return the font name in specified cell range as a string.

See also: SetRangeFontName SelectRangeByIndex

#### GetRangeFontSize [::Excel]

Excel, Top

Get the font size of a cell range.

GetRangeFontSize rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Get the font size of a cell range.

Return the size of the font in specified cell range measured in points.

See also: SetRangeFontSize SelectRangeByIndex

#### GetRangeFontSubscript [::Excel]

Excel, Top

Get the subscript font style of a cell or character range.

GetRangeFontSubscript rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Get the subscript font style of a cell or character range.

Return true, if the font in specified cell range has the subscript flag set.

See also: SetRangeFontSubscript SelectRangeByIndex

#### GetRangeFontSuperscript [::Excel]

Excel, Top

Get the superscript font style of a cell or character range.

GetRangeFontSuperscript rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Get the superscript font style of a cell or character range.

Return true, if the font in specified cell range has the superscript flag set.

See also: SetRangeFontSuperscript SelectRangeByIndex GetRangeCharacters

#### GetRangeFontUnderline [::Excel]

Excel, Top

Get the underline font style of a cell range.

GetRangeFontUnderline rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Get the underline font style of a cell range.

Return the underline style of specified cell range. The returned value is of enumeration type XlUnderlineStyle (see excelConst.tcl).

See also: SetRangeFontUnderline SelectRangeByIndex

#### GetRangeFormat [::Excel]

Excel, Top

Get the number format of a cell range.

GetRangeFormat rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Return value

Returns the number format in Excel style.

###### Description

Get the number format of a cell range.

See also: SetRangeFormat SelectRangeByIndex SelectRangeByString

#### GetRangeHorizontalAlignment [::Excel]

Excel, Top

Get the horizontal alignment of a cell range.

GetRangeHorizontalAlignment rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Get the horizontal alignment of a cell range.

Return the horizontal alignment as a value of enumeration type XlHAlign (see excelConst.tcl).

See also: SetRangeHorizontalAlignment SelectRangeByIndex SelectRangeByString

#### GetRangeTextColor [::Excel]

Excel, Top

Get the text color of a cell range.

GetRangeTextColor rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Get the text color of a cell range.

The r, g and b values are returned as integers in the range [0, 255].

Return the text color as a list of r, b and b values.

See also: SetRangeTextColor ::Cawt::OfficeColorToRgb SelectRangeByIndex SelectRangeByString

#### GetRangeValues [::Excel]

Excel, Top

Return range values as a matrix.

GetRangeValues rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Return range values as a matrix.

See also: SetRangeValues GetMatrixValues GetRowValues GetColumnValues GetCellValue

#### GetRangeVerticalAlignment [::Excel]

Excel, Top

Get the vertical alignment of a cell range.

GetRangeVerticalAlignment rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Get the vertical alignment of a cell range.

Return the vertical alignment as a value of enumeration type XlVAlign (see excelConst.tcl).

See also: SetRangeVerticalAlignment SelectRangeByIndex SelectRangeByString

#### GetRangeWrapText [::Excel]

Excel, Top

Get the wrap text mode of a cell range.

GetRangeWrapText rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Description

Get the wrap text mode of a cell range.

Return true, if the specified cell range has the wrap text flag set.

See also: SetRangeWrapText GetRangeHorizontalAlignment GetRangeTextColor SelectRangeByIndex

#### GetRowValues [::Excel]

Excel, Top

Return row values as a Tcl list.

GetRowValues worksheetId row startCol numVals

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.
startCol | (optional, default 0) Column number of start. Column numbering starts with 1. Negative or zero: Start at first available column.
numVals | (optional, default 0) Negative or zero: All available row values are returned. Positive: Only numVals values of the row are returned.

###### Description

Return row values as a Tcl list.

Note, that the functionality of this procedure has changed slightly with CAWT versions greater than 1.0.5: If "startCol" is not specified, "startCol" is not set to 1, but it is set to the first available row. Possible incompatibility.

Return the values of the specified row or row range as a Tcl list.

See also: SetRowValues GetColumnValues GetCellValue ColumnCharToInt GetFirstUsedColumn

#### GetTablelistHeader [::Excel]

Excel, Top

Return the header line of a tablelist as a list.

GetTablelistHeader tableId

###### Parameters

tableId | Identifier of the tablelist.

###### Description

Return the header line of a tablelist as a list.

See also: TablelistToWorksheet WorksheetToTablelist SetTablelistHeader GetTablelistValues

#### GetTablelistValues [::Excel]

Excel, Top

Return the values of a tablelist as a matrix.

GetTablelistValues tableId

###### Parameters

tableId | Identifier of the tablelist.

###### Description

Return the values of a tablelist as a matrix.

See also: TablelistToWorksheet WorksheetToTablelist SetTablelistValues GetTablelistHeader

#### GetThousandsSeparator [::Excel]

Excel, Top

Return the thousands separator used by Excel.

GetThousandsSeparator appId

###### Parameters

appId | Identifier of the Excel instance.

###### Description

Return the thousands separator used by Excel.

See also: GetVersion GetDecimalSeparator

#### GetVersion [::Excel]

Excel, Top

Return the version of an Excel application.

GetVersion objId useString

###### Parameters

objId | Identifier of an Excel object instance.
useString | (optional, default false) true: Return the version name (ex. "Excel 2000"). false: Return the version number (ex. "9.0").

###### Description

Return the version of an Excel application.

Both version name and version number are returned as strings. Version number is in a format, so that it can be evaluated as a floating point number.

See also: GetDecimalSeparator GetExtString

#### GetWorkbookIdByName [::Excel]

Excel, Top

Find an open workbook by its name.

GetWorkbookIdByName appId workbookName

###### Parameters

appId | Identifier of the Excel instance.
workbookName | Name of the workbook to find.

###### Description

Find an open workbook by its name.

Return the identifier of the found workbook. If a workbook with given name does not exist an error is thrown.

See also: OpenWorkbook GetActiveWorkbook GetWorkbookName GetWorksheetIdByName

#### GetWorkbookName [::Excel]

Excel, Top

Return the name of a workbook.

GetWorkbookName workbookId

###### Parameters

workbookId | Identifier of the workbook.

###### Description

Return the name of a workbook.

See also: AddWorkbook

#### GetWorksheetAsMatrix [::Excel]

Excel, Top

Return worksheet table as a matrix.

GetWorksheetAsMatrix worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Description

Return worksheet table as a matrix.

Return the range of the worksheet with valid data as a matrix.

See also: SetMatrixValues GetMatrixValues GetFirstUsedRow GetLastUsedRow

#### GetWorksheetIdByIndex [::Excel]

Excel, Top

Find a worksheet by its index.

GetWorksheetIdByIndex workbookId index activate

###### Parameters

workbookId | Identifier of the workbook containing the worksheet.
index | Index of the worksheet to find.
activate | (optional, default true) true: Activate the found worksheet. false: Just return the identifier.

###### Description

Find a worksheet by its index.

Return the identifier of the found worksheet. The left-most worksheet has index 1. Instead of using the numeric index the special word "end" may be used to specify the last worksheet. If the index is out of bounds an error is thrown.

See also: GetNumWorksheets GetWorksheetIdByName AddWorksheet

#### GetWorksheetIdByName [::Excel]

Excel, Top

Find a worksheet by its name.

GetWorksheetIdByName workbookId worksheetName activate

###### Parameters

workbookId | Identifier of the workbook containing the worksheet.
worksheetName | Name of the worksheet to find.
activate | (optional, default true) true: Activate the found worksheet. false: Just return the identifier.

###### Description

Find a worksheet by its name.

Return the identifier of the found worksheet. If a worksheet with given name does not exist an error is thrown.

See also: GetNumWorksheets GetWorksheetIndexByName GetWorksheetIdByIndex AddWorksheet GetWorkbookIdByName

#### GetWorksheetIndexByName [::Excel]

Excel, Top

Find a worksheet index by its name.

GetWorksheetIndexByName workbookId worksheetName activate

###### Parameters

workbookId | Identifier of the workbook containing the worksheet.
worksheetName | Name of the worksheet to find.
activate | (optional, default true) true: Activate the found worksheet. false: Just return the index.

###### Description

Find a worksheet index by its name.

Return the index of the found worksheet. The left-most worksheet has index 1. If a worksheet with given name does not exist an error is thrown.

See also: GetNumWorksheets GetWorksheetIdByIndex GetWorksheetIdByName AddWorksheet

#### GetWorksheetName [::Excel]

Excel, Top

Return the name of a worksheet.

GetWorksheetName worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Description

Return the name of a worksheet.

See also: SetWorksheetName AddWorksheet

#### HideColumn [::Excel]

Excel, Top

Hide or unhide a column.

HideColumn worksheetId col hide

###### Parameters

worksheetId | Identifier of the worksheet.
col | Column number. Column numbering starts with 1.
hide | (optional, default true) If set to true, the specified column is hidden, otherwise it is shown.

###### Return value

Returns no value.

###### Description

Hide or unhide a column.

See also: InsertColumn DeleteColumn DuplicateColumn GetHiddenColumns HideRow

#### HideRow [::Excel]

Excel, Top

Hide or unhide a row.

HideRow worksheetId row hide

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.
hide | (optional, default true) If set to true, the specified row is hidden, otherwise it is shown.

###### Return value

Returns no value.

###### Description

Hide or unhide a row.

See also: InsertRow DeleteRow DuplicateRow GetHiddenRows HideColumn

#### ImgToWorksheet [::Excel]

Excel, Top

Put a photo image into a worksheet.

ImgToWorksheet phImg worksheetId row col rowHeight colWidth

###### Parameters

phImg | The photo image identifier.
worksheetId | Identifier of the worksheet.
row | (optional, default 1) Row number of the top-left corner of the image. Row numbering starts with 1.
col | (optional, default 1) Column number of the top-left corner of the image. Column numbering starts with 1.
rowHeight | (optional, default 9) Row height.
colWidth | (optional, default 1) Column width in average-size characters of the widget's font.

###### Return value

Returns no value.

###### Description

Put a photo image into a worksheet.

The height value may be specified in a format acceptable by procedure ::Cawt::ValueToPoints, i.e. centimeters, inches or points.

Note: Use only with small images.

See also: WorksheetToImg UseImgTransparency ::Cawt::ValueToPoints ::Cawt::ImgToClipboard RawImageFileToWorksheet SetRowHeight SetColumnWidth

#### Import [::Excel]

Excel, Top

Import data from an external data source.

Import rangeId fileName args

###### Parameters

rangeId | Identifier of the cell range.
fileName | File name of the data source.
args | List of key value pairs specifying import configure options and its values.

###### Return value

Returns no value.

###### Description

Import data from an external data source.

Option keys:

-delimiter

       Delimiter character. Possible values: "\t" " " ";" ","

-decimalseparator

       Decimal separator character.

-thousandsseparator

       Thousands separator character.

See also: OpenWorkbook SaveAsCsv

#### InsertColumn [::Excel]

Excel, Top

Insert a new empty column.

InsertColumn worksheetId col

###### Parameters

worksheetId | Identifier of the worksheet.
col | Column number. Column numbering starts with 1.

###### Return value

Returns no value.

###### Description

Insert a new empty column.

A new empty column is inserted at given column number.

See also: DeleteColumn DuplicateColumn HideColumn InsertRow

#### InsertImage [::Excel]

Excel, Top

Insert an image into a worksheet.

InsertImage worksheetId imgFileName row col linkToFile saveWithDoc

###### Parameters

worksheetId | Identifier of the worksheet where the image is inserted.
imgFileName | File name of the image.
row | (optional, default 1) Row number. Row numbering starts with 1.
col | (optional, default 1) Column number. Column numbering starts with 1.
linkToFile | (optional, default false) Insert a link to the image file.
saveWithDoc | (optional, default true) Embed the image into the document.

###### Description

Insert an image into a worksheet.

The file name of the image must be an absolute pathname. Use a construct like [file join [pwd] "myImage.gif"] to insert images from the current directory.

If both linkToFile and saveWithDoc are set to false, an error is thrown.

Return the identifier of the inserted image as a shape.

See also: ScaleImage

#### InsertRow [::Excel]

Excel, Top

Insert a new empty row.

InsertRow worksheetId row

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.

###### Return value

Returns no value.

###### Description

Insert a new empty row.

A new empty row is inserted at given row number.

See also: DeleteRow DuplicateRow HideRow InsertColumn

#### IsWorkbookId [::Excel]

Excel, Top

Check, if Excel object is a workbook identifier.

IsWorkbookId objId

###### Parameters

objId | The identifier of an Excel object.

###### Description

Check, if Excel object is a workbook identifier.

Return true, if objId is a valid Excel workbook identifier. Otherwise return false.

See also: ::Cawt::IsComObject ::Office::GetApplicationId

#### IsWorkbookOpen [::Excel]

Excel, Top

Check, if a workbook is open.

IsWorkbookOpen appId workbookName

###### Parameters

appId | Identifier of the Excel instance.
workbookName | Name of the workbook to find.

###### Description

Check, if a workbook is open.

Return true, if the workbook is open, otherwise false.

See also: OpenWorkbook IsWorkbookProtected

#### IsWorkbookProtected [::Excel]

Excel, Top

Check, if a workbook is protected.

IsWorkbookProtected workbookId

###### Parameters

workbookId | Identifier of the workbook to be checked.

###### Description

Check, if a workbook is protected.

Return true, if the workbook is protected, otherwise false.

See also: OpenWorkbook IsWorkbookOpen

#### IsWorksheetEmpty [::Excel]

Excel, Top

Check, if a worksheet is empty.

IsWorksheetEmpty worksheetId

###### Parameters

worksheetId | Identifier of the worksheet to be checked.

###### Description

Check, if a worksheet is empty.

Return true, if the worksheet is empty, otherwise false.

See also: GetNumUsedRows GetNumUsedColumns GetFirstUsedRow GetLastUsedRow

#### IsWorksheetProtected [::Excel]

Excel, Top

Check, if a worksheet is content protected.

IsWorksheetProtected worksheetId

###### Parameters

worksheetId | Identifier of the worksheet to be checked.

###### Description

Check, if a worksheet is content protected.

Return true, if the worksheet is protected, otherwise false.

See also: AddWorksheet

#### IsWorksheetVisible [::Excel]

Excel, Top

Check, if a worksheet is visible.

IsWorksheetVisible worksheetId

###### Parameters

worksheetId | Identifier of the worksheet to be checked.

###### Description

Check, if a worksheet is visible.

Return true, if the worksheet is visible, otherwise false.

See also: AddWorksheet

#### ListToCsvRow [::Excel]

Excel, Top

Return a list of column values as a CSV encoded row string.

ListToCsvRow rowList

###### Parameters

rowList | List of column values.

###### Description

Return a list of column values as a CSV encoded row string.

See also: CsvRowToList

#### MatlabFileToExcelFile [::Excel]

Excel, Top

Convert a Matlab table file to an Excel file.

MatlabFileToExcelFile matFileName excelFileName useHeader quitExcel

###### Parameters

matFileName | Name of the Matlab input file.
excelFileName | Name of the Excel output file.
useHeader | (optional, default true) true: Insert the header of the Matlab file as first row. false: Only transfer the data values as floating point values.
quitExcel | (optional, default true) true: Quit the Excel instance after generation of output file. false: Leave the Excel instance open after generation of output file.

###### Return value

Returns the Excel application identifier, if quitExcel is false. Otherwise no return value.

###### Description

Convert a Matlab table file to an Excel file.

The table data from the Matlab file will be inserted into a worksheet name "Matlab".

See also: MatlabFileToWorksheet ExcelFileToMatlabFile ReadMatlabFile

#### MatlabFileToWorksheet [::Excel]

Excel, Top

Insert the data values of a Matlab file into a worksheet.

MatlabFileToWorksheet matFileName worksheetId useHeader

###### Parameters

matFileName | Name of the Matlab file.
worksheetId | Identifier of the worksheet.
useHeader | (optional, default true) true: Insert the header of the Matlab file as first row. false: Only transfer the data values as floating point values.

###### Return value

Returns no value.

###### Description

Insert the data values of a Matlab file into a worksheet.

The header information are as follows: MatlabVersion Width Height

Note: Only Matlab Level 4 files are currently supported.

See also: WorksheetToMatlabFile SetMatrixValues WikitFileToWorksheet MediaWikiFileToWorksheet RawImageFileToWorksheet TablelistToWorksheet WordTableToWorksheet

#### MatrixToClipboard [::Excel]

Excel, Top

Copy a matrix into the clipboard.

MatrixToClipboard matrixList sepChar

###### Parameters

matrixList | Matrix with table data.
sepChar | (optional, default ;) The separation character of the clipboard matrix data.

###### Return value

Returns no value.

###### Description

Copy a matrix into the clipboard.

The clipboard data will be in CSV format with sepChar as separation character. See SetMatrixValues for the description of a matrix representation.

See also: WorksheetToClipboard ClipboardToMatrix

#### MatrixToCsvString [::Excel]

Excel, Top

Return a CSV encoded table string from a matrix list.

MatrixToCsvString matrixList

###### Parameters

matrixList | Matrix with table data.

###### Description

Return a CSV encoded table string from a matrix list.

See also: CsvStringToMatrix ListToCsvRow

#### MediaWikiFileToExcelFile [::Excel]

Excel, Top

Convert a MediaWiki table file to an Excel file.

MediaWikiFileToExcelFile wikiFileName excelFileName useHeader quitExcel

###### Parameters

wikiFileName | Name of the MediaWiki input file.
excelFileName | Name of the Excel output file.
useHeader | (optional, default true) true: Use header information from the MediaWiki file to generate an Excel header (see SetHeaderRow). false: Only transfer the table data.
quitExcel | (optional, default true) true: Quit the Excel instance after generation of output file. false: Leave the Excel instance open after generation of output file.

###### Return value

Returns the Excel application identifier, if quitExcel is false. Otherwise no return value.

###### Description

Convert a MediaWiki table file to an Excel file.

The table data from the MediaWiki file will be inserted into a worksheet named "MediaWiki".

See also: MediaWikiFileToWorksheet ExcelFileToMediaWikiFile ReadMediaWikiFile WriteMediaWikiFile WikitFileToExcelFile

#### MediaWikiFileToWorksheet [::Excel]

Excel, Top

Insert the values of a MediaWiki table file into a worksheet.

MediaWikiFileToWorksheet wikiFileName worksheetId useHeader

###### Parameters

wikiFileName | Name of the MediaWiki file.
worksheetId | Identifier of the worksheet.
useHeader | (optional, default true) true: Insert the header of the MediaWiki table as first row. false: Only transfer the table data.

###### Return value

Returns no value.

###### Description

Insert the values of a MediaWiki table file into a worksheet.

The insertion starts at row and column 1. Values contained in the worksheet cells are overwritten.

See also: WorksheetToMediaWikiFile SetMatrixValues WikitFileToWorksheet WordTableToWorksheet MatlabFileToWorksheet RawImageFileToWorksheet TablelistToWorksheet

#### Open [::Excel]

Excel, Top

Open an Excel instance. Use an already running instance, if available.

Open visible width height

###### Parameters

visible | (optional, default true) true: Show the application window. false: Hide the application window.
width | (optional, default -1) Width of the application window. If negative, open with last used width.
height | (optional, default -1) Height of the application window. If negative, open with last used height.

###### Description

Open an Excel instance. Use an already running instance, if available.

Return the identifier of the Excel application instance.

See also: OpenNew Quit Visible

#### OpenNew [::Excel]

Excel, Top

Open a new Excel instance.

OpenNew visible width height

###### Parameters

visible | (optional, default true) true: Show the application window. false: Hide the application window.
width | (optional, default -1) Width of the application window. If negative, open with last used width.
height | (optional, default -1) Height of the application window. If negative, open with last used height.

###### Description

Open a new Excel instance.

Return the identifier of the new Excel application instance.

See also: Open Quit Visible

#### OpenWorkbook [::Excel]

Excel, Top

Open a workbook, i.e. load an Excel file.

OpenWorkbook appId fileName readOnly

###### Parameters

appId | Identifier of the Excel instance.
fileName | Name of the Excel file.
readOnly | (optional, default false) true: Open the workbook in read-only mode. false: Open the workbook in read-write mode.

###### Description

Open a workbook, i.e. load an Excel file.

Return the identifier of the opened workbook. If the workbook was already open, activate that workbook and return the identifier to that workbook.

See also: AddWorkbook Close SaveAs

#### PlaceChart [::Excel]

Excel, Top

Place an existing chart into a worksheet.

PlaceChart chartId worksheetId

###### Parameters

chartId | Identifier of the chart.
worksheetId | Identifier of the worksheet.

###### Description

Place an existing chart into a worksheet.

Return the ChartObject identifier of the placed chart.

See also: CreateChart SetChartObjSize SetChartObjPosition

#### Quit [::Excel]

Excel, Top

Quit an Excel instance.

Quit appId showAlert

###### Parameters

appId | Identifier of the Excel instance.
showAlert | (optional, default true) true: Show an alert window, if there are unsaved changes. false: Quit without asking and saving any changes.

###### Return value

Returns no value.

###### Description

Quit an Excel instance.

See also: Open OpenNew

#### RawImageFileToExcelFile [::Excel]

Excel, Top

Convert a raw photo image file to an Excel file.

RawImageFileToExcelFile rawFileName excelFileName useHeader quitExcel

###### Parameters

rawFileName | Name of the raw photo image input file.
excelFileName | Name of the Excel output file.
useHeader | (optional, default true) true: Use header information from the image file to generate an Excel header (see SetHeaderRow). false: Only transfer the image data.
quitExcel | (optional, default true) true: Quit the Excel instance after generation of output file. false: Leave the Excel instance open after generation of output file.

###### Description

Convert a raw photo image file to an Excel file.

The table data from the image file will be inserted into a worksheet name "RawImage".

Return the Excel application identifier, if quitExcel is false. Otherwise no return value.

See also: RawImageFileToWorksheet ExcelFileToRawImageFile ReadRawImageFile WriteRawImageFile

#### RawImageFileToWorksheet [::Excel]

Excel, Top

Insert the pixel values of a raw photo image into a worksheet.

RawImageFileToWorksheet rawFileName worksheetId useHeader

###### Parameters

rawFileName | File name of the image.
worksheetId | Identifier of the worksheet.
useHeader | (optional, default true) true: Insert the header of the raw image as first row. false: Only transfer the pixel values as floating point values.

###### Return value

Returns no value.

###### Description

Insert the pixel values of a raw photo image into a worksheet.

The header information are as follows: Magic Width Height NumChan ByteOrder ScanOrder PixelType

Note: Only 1-channel floating-point raw images are currently supported.

See also: WorksheetToRawImageFile SetMatrixValues WikitFileToWorksheet MediaWikiFileToWorksheet MatlabFileToWorksheet TablelistToWorksheet WordTableToWorksheet

#### ReadCsvFile [::Excel]

Excel, Top

Read a CSV table file into a matrix.

ReadCsvFile csvFileName useHeader numHeaderRows

###### Parameters

csvFileName | Name of the CSV file.
useHeader | (optional, default true) true: Insert the header rows of the CSV file into the matrix. false: Only transfer the table data.
numHeaderRows | (optional, default 0) Number of rows interpreted as header rows.

###### Description

Read a CSV table file into a matrix.

Return the CSV table data as a matrix. See SetMatrixValues for the description of a matrix representation.

See also: WriteCsvFile

#### ReadMatlabFile [::Excel]

Excel, Top

Read a Matlab file into a matrix.

ReadMatlabFile matFileName

###### Parameters

matFileName | Name of the Matlab file.

###### Return value

Returns the Matlab file data as a matrix. See SetMatrixValues for the description of a matrix representation.

###### Description

Read a Matlab file into a matrix.

Note: Only Matlab Level 4 files are currently supported.

See also: ReadMatlabHeader WriteMatlabFile MatlabFileToWorksheet

#### ReadMatlabHeader [::Excel]

Excel, Top

Read the header of a Matlab file.

ReadMatlabHeader matFileName

###### Parameters

matFileName | Name of the Matlab file.

###### Return value

Returns the header information as a list of integers containing the following values: MatlabVersion Width Height

###### Description

Read the header of a Matlab file.

See also: ReadMatlabFile

#### ReadMediaWikiFile [::Excel]

Excel, Top

Read a MediaWiki table file into a matrix.

ReadMediaWikiFile wikiFileName useHeader

###### Parameters

wikiFileName | Name of the MediaWiki file.
useHeader | (optional, default true) true: Insert the header of the MediaWiki table as first row. false: Only transfer the table data.

###### Return value

Returns the MediaWiki table data as a matrix. See SetMatrixValues for the description of a matrix representation.

###### Description

Read a MediaWiki table file into a matrix.

See also: WriteMediaWikiFile MediaWikiFileToWorksheet

#### ReadRawImageFile [::Excel]

Excel, Top

Read a raw photo image into a matrix.

ReadRawImageFile rawImgFile

###### Parameters

rawImgFile | File name of the image.

###### Description

Read a raw photo image into a matrix.

Note: Only 1-channel floating-point raw images are currently supported.

Return the image data as a matrix. See SetMatrixValues for the description of a matrix representation.

See also: ReadRawImageHeader WriteRawImageFile RawImageFileToWorksheet

#### ReadRawImageHeader [::Excel]

Excel, Top

Read the header of a raw photo image.

ReadRawImageHeader rawImgFile

###### Parameters

rawImgFile | File name of the image.

###### Description

Read the header of a raw photo image.

Return the header information as a list containing the following values: Magic Width Height NumChan ByteOrder ScanOrder PixelType

See also: ReadRawImageFile

#### ReadWikitFile [::Excel]

Excel, Top

Read a Wikit table file into a matrix.

ReadWikitFile wikiFileName useHeader

###### Parameters

wikiFileName | Name of the Wikit file.
useHeader | (optional, default true) true: Insert the header of the Wikit table as first row. false: Only transfer the table data.

###### Description

Read a Wikit table file into a matrix.

Return the Wikit table data as a matrix. See SetMatrixValues for the description of a matrix representation.

See also: WriteWikitFile WikitFileToWorksheet

#### ResizeChartObj [::Excel]

Excel, Top

Set the position and size of a chart object.

ResizeChartObj chartObjId rangeId

###### Parameters

chartObjId | Identifier of the chart object.
rangeId | Identifier of the cell range.

###### Return value

Returns no value.

###### Description

Set the position and size of a chart object.

Resize the chart object so that it fits into the specified cell range.

See also: PlaceChart SetChartObjSize SetChartObjPosition SelectRangeByString

#### SaveAs [::Excel]

Excel, Top

Save a workbook to an Excel file.

SaveAs workbookId fileName fmt backup

###### Parameters

workbookId | Identifier of the workbook to save.
fileName | Name of the Excel file.
fmt | (optional, default ) Value of enumeration type XlFileFormat (see excelConst.tcl). If not given or the empty string, the file is stored in the native format corresponding to the used Excel version.
backup | (optional, default false) true: Create a backup file before saving. false: Do not create a backup file.

###### Return value

Returns no value.

###### Description

Save a workbook to an Excel file.

Note, that if you have read a CSV file with OpenWorkbook and save it with this procedure without specifying a format, the saved file will be in CSV format, too. Specify xlWorkbookDefault as format, if the file should be an Excel file.

See also: SaveAsCsv Close OpenWorkbook

#### SaveAsCsv [::Excel]

Excel, Top

Save a worksheet to file in CSV format.

SaveAsCsv workbookId worksheetId fileName fmt

###### Parameters

workbookId | Identifier of the workbook containing the worksheet.
worksheetId | Identifier of the worksheet to save.
fileName | Name of the CSV file.
fmt | (optional, default xlCSV) Value of enumeration type XlFileFormat (see excelConst.tcl). If not given, the file is stored in xlCSV format.

###### Return value

Returns no value.

###### Description

Save a worksheet to file in CSV format.

See also: SaveAs Close OpenWorkbook

#### SaveChartAsImage [::Excel]

Excel, Top

Obsolete: Replaced with SaveChartObjAsImage in version 1.0.1

SaveChartAsImage chartId fileName filterType

###### Parameters

chartId |
fileName |
filterType | (optional, default GIF)

###### Description

Obsolete: Replaced with SaveChartObjAsImage in version 1.0.1

#### SaveChartObjAsImage [::Excel]

Excel, Top

Save a chart as an image in a file.

SaveChartObjAsImage chartObjId fileName filterType

###### Parameters

chartObjId | Identifier of the chart object.
fileName | Image file name.
filterType | (optional, default GIF) Name of graphic filter. Possible values: GIF, JPEG, PNG.

###### Return value

Returns no value.

###### Description

Save a chart as an image in a file.

See also: ChartObjToClipboard CreateChart

#### ScaleImage [::Excel]

Excel, Top

Scale an image.

ScaleImage shapeId scaleWidth scaleHeight

###### Parameters

shapeId | Identifier of the image shape.
scaleWidth | Horizontal scale factor.
scaleHeight | Vertical scale factor.

###### Return value

Returns no value.

###### Description

Scale an image.

The scale factors are floating point values. 1.0 means no scaling.

See also: InsertImage

#### ScreenUpdate [::Excel]

Excel, Top

Toggle the screen updating of an Excel application window.

ScreenUpdate appId onOff

###### Parameters

appId | Identifier of the Excel instance.
onOff | true: Update the application window. false: Do not update the application window.

###### Return value

Returns no value.

###### Description

Toggle the screen updating of an Excel application window.

See also: Visible SetWindowState ArrangeWindows

#### Search [::Excel]

Excel, Top

Find a string in a worksheet cell range.

Search worksheetId str row1 col1 row2 col2

###### Parameters

worksheetId | Identifier of the worksheet.
str | Search string.
row1 | (optional, default 1) Row number of upper-left corner of the cell range.
col1 | (optional, default 1) Column number of upper-left corner of the cell range.
row2 | (optional, default -1) Row number of lower-right corner of the cell range.
col2 | (optional, default -1) Column number of lower-right corner of the cell range.

###### Description

Find a string in a worksheet cell range.

If row2 or col2 is negative, all used rows and columns are searched.

Return the first matching cell as a 2-element list {row, col} of indices. If no cell matches the search criteria, an empty list is returned.

#### SelectAll [::Excel]

Excel, Top

Select all cells of a worksheet.

SelectAll worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Description

Select all cells of a worksheet.

Return the cells collection of the selected cells.

See also: CopyWorksheet

#### SelectCellByIndex [::Excel]

Excel, Top

Select a cell by its row/column index.

SelectCellByIndex worksheetId row col visSel

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.
visSel | (optional, default false) true: See the selection in the user interface. false: The selection is not visible.

###### Description

Select a cell by its row/column index.

Return the identifier of the cell as a range identifier.

See also: SelectRangeByIndex AddWorksheet

#### SelectRangeByIndex [::Excel]

Excel, Top

Select a range by specifying a numeric cell range.

SelectRangeByIndex worksheetId row1 col1 row2 col2 visSel

###### Parameters

worksheetId | Identifier of the worksheet.
row1 | Row number of upper-left corner of the cell range.
col1 | Column number of upper-left corner of the cell range.
row2 | Row number of lower-right corner of the cell range.
col2 | Column number of lower-right corner of the cell range.
visSel | (optional, default false) true: See the selection in the user interface. false: The selection is not visible.

###### Description

Select a range by specifying a numeric cell range.

Return the range identifier of the cell range.

See also: SelectCellByIndex GetCellRange

#### SelectRangeByString [::Excel]

Excel, Top

Select a range by specifying an Excel range string in A1 notation.

SelectRangeByString worksheetId rangeStr visSel

###### Parameters

worksheetId | Identifier of the worksheet.
rangeStr | String specifying a cell range, ex. "A8:C10".
visSel | (optional, default false) true: See the selection in the user interface. false: The selection is not visible.

###### Description

Select a range by specifying an Excel range string in A1 notation.

Return the range identifier of the cell range.

See also: SelectRangeByIndex GetCellRange

#### SetCellValue [::Excel]

Excel, Top

Set the value of a cell.

SetCellValue worksheetId row col val fmt subFmt

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.
val | String value of the cell.
fmt | (optional, default text) Format of the cell. Possible values: "text", "int", "real".
subFmt | (optional, default ) Formatting option of the floating-point value (see SetRangeFormat).

###### Return value

Returns no value.

###### Description

Set the value of a cell.

The value to be inserted is interpreted either as string, integer or floating-point number according to the formats specified in "fmt" and "subFmt".

See also: GetCellValue SetRowValues SetMatrixValues

#### SetChartMaxScale [::Excel]

Excel, Top

Set the maximum scale of an axis of a chart.

SetChartMaxScale chartId axisName value

###### Parameters

chartId | Identifier of the chart.
axisName | Name of axis. Possible values: "x" or "y".
value | Scale value.

###### Return value

Returns no value.

###### Description

Set the maximum scale of an axis of a chart.

See also: SetChartMinScale SetChartScale SetChartObjSize

#### SetChartMinScale [::Excel]

Excel, Top

Set the minimum scale of an axis of a chart.

SetChartMinScale chartId axisName value

###### Parameters

chartId | Identifier of the chart.
axisName | Name of axis. Possible values: "x" or "y".
value | Scale value.

###### Return value

Returns no value.

###### Description

Set the minimum scale of an axis of a chart.

See also: SetChartMaxScale SetChartScale SetChartObjSize

#### SetChartObjPosition [::Excel]

Excel, Top

Set the position of a chart object.

SetChartObjPosition chartObjId left top

###### Parameters

chartObjId | Identifier of the chart object.
left | Left border of the chart object in pixel.
top | Top border of the chart object in pixel.

###### Return value

Returns no value.

###### Description

Set the position of a chart object.

See also: PlaceChart SetChartObjSize SetChartScale

#### SetChartObjSize [::Excel]

Excel, Top

Set the size of a chart object.

SetChartObjSize chartObjId width height

###### Parameters

chartObjId | Identifier of the chart object.
width | Width of the chart object in pixel.
height | Height of the chart object in pixel.

###### Return value

Returns no value.

###### Description

Set the size of a chart object.

See also: PlaceChart SetChartObjPosition SetChartScale

#### SetChartScale [::Excel]

Excel, Top

Set the minimum and maximum scale of both axes of a chart.

SetChartScale chartId xmin xmax ymin ymax

###### Parameters

chartId | Identifier of the chart.
xmin | Minimum scale value of x axis.
xmax | Maximum scale value of x axis.
ymin | Minimum scale value of y axis.
ymax | Maximum scale value of y axis.

###### Return value

Returns no value.

###### Description

Set the minimum and maximum scale of both axes of a chart.

See also: SetChartMinScale SetChartMaxScale SetChartObjSize

#### SetChartSize [::Excel]

Excel, Top

Obsolete: Replaced with SetChartObjSize in version 1.0.1

SetChartSize worksheetId chartId width height

###### Parameters

worksheetId |
chartId |
width |
height |

###### Description

Obsolete: Replaced with SetChartObjSize in version 1.0.1

#### SetChartSourceByIndex [::Excel]

Excel, Top

Set the cell range for the source of a chart.

SetChartSourceByIndex chartId worksheetId row1 col1 row2 col2 type

###### Parameters

chartId | Identifier of the chart.
worksheetId | Identifier of the worksheet.
row1 | Row number of upper-left corner of the cell range.
col1 | Column number of upper-left corner of the cell range.
row2 | Row number of lower-right corner of the cell range.
col2 | Column number of lower-right corner of the cell range.
type | (optional, default xlColumns) Value of enumeration type XlRowCol (see excelConst.tcl).

###### Return value

Returns no value.

###### Description

Set the cell range for the source of a chart.

See also: CreateChart SetChartTitle SetChartScale

#### SetChartTicks [::Excel]

Excel, Top

Set the tick spacing of an axis of a chart.

SetChartTicks chartId axisName tickMarkSpacing tickLabelSpacing

###### Parameters

chartId | Identifier of the chart.
axisName | Name of axis. Possible values: "x" or "y".
tickMarkSpacing | (optional, default ) Spacing of tick marks.
tickLabelSpacing | (optional, default ) Spacing of tick labels.

###### Return value

Returns no value.

###### Description

Set the tick spacing of an axis of a chart.

If spacing values are not specified or the emtpy string, the corresponding spacing uses the default values, which are automatically determined by Excel.

See also: SetChartMaxScale SetChartScale SetChartObjSize

#### SetChartTitle [::Excel]

Excel, Top

Set the title of a chart.

SetChartTitle chartId title

###### Parameters

chartId | Identifier of the chart.
title | Name of the chart title.

###### Return value

Returns no value.

###### Description

Set the title of a chart.

See also: SetChartMinScale SetChartScale CreateChart

#### SetColumnsWidth [::Excel]

Excel, Top

Set the width of a range of columns.

SetColumnsWidth worksheetId startCol endCol width

###### Parameters

worksheetId | Identifier of the worksheet.
startCol | Range start column number. Column numbering starts with 1.
endCol | Range end column number. Column numbering starts with 1.
width | (optional, default 0) A positive value specifies the column's width in average-size characters of the widget's font. A value of zero specifies that the column's width fits automatically the width of all elements in the column.

###### Return value

Returns no value.

###### Description

Set the width of a range of columns.

See also: SetColumnWidth ColumnCharToInt

#### SetColumnValues [::Excel]

Excel, Top

Insert column values from a Tcl list.

SetColumnValues worksheetId col valList startRow numVals

###### Parameters

worksheetId | Identifier of the worksheet.
col | Column number. Column numbering starts with 1.
valList | List of values to be inserted.
startRow | (optional, default 1) Row number of insertion start. Row numbering starts with 1.
numVals | (optional, default 0) Negative or zero: All list values are inserted. Positive: numVals rows are filled with the list values (starting at list index 0).

###### Return value

Returns no value.

###### Description

Insert column values from a Tcl list.

See also: GetColumnValues SetRowValues SetCellValue ColumnCharToInt

#### SetColumnWidth [::Excel]

Excel, Top

Set the width of a column.

SetColumnWidth worksheetId col width

###### Parameters

worksheetId | Identifier of the worksheet.
col | Column number. Column numbering starts with 1.
width | (optional, default 0) A positive value specifies the column's width in average-size characters of the widget's font. A value of zero specifies that the column's width fits automatically the width of all elements in the column.

###### Return value

Returns no value.

###### Description

Set the width of a column.

See also: SetColumnsWidth ColumnCharToInt

#### SetCommentDisplayMode [::Excel]

Excel, Top

Set the global display mode of comments.

SetCommentDisplayMode appId showComment showIndicator

###### Parameters

appId | Identifier of the Excel instance.
showComment | (optional, default false) true: Show the comments. false: Do not show the comments.
showIndicator | (optional, default true) true: Show an indicator for the comments. false: Do not show an indicator.

###### Return value

Returns no value.

###### Description

Set the global display mode of comments.

See also: SetRangeComment SetCommentSize GetCellComment

#### SetCommentSize [::Excel]

Excel, Top

Set the shape size of a comment.

SetCommentSize commentId width height

###### Parameters

commentId | Identifier of the comment.
width | Width of the comment.
height | Height of the comment.

###### Return value

Returns no value.

###### Description

Set the shape size of a comment.

The size values may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: SetRangeComment SetCommentDisplayMode GetCellComment ::Cawt::ValueToPoints

#### SetCsvSeparatorChar [::Excel]

Excel, Top

Set the column separator character.

SetCsvSeparatorChar separatorChar

###### Parameters

separatorChar | (optional, default ;) The character used as the column separator.

###### Description

Set the column separator character.

#### SetHeaderRow [::Excel]

Excel, Top

Insert row values from a Tcl list and format as a header row.

SetHeaderRow worksheetId headerList row startCol

###### Parameters

worksheetId | Identifier of the worksheet.
headerList | List of values to be inserted as header.
row | (optional, default 1) Row number. Row numbering starts with 1.
startCol | (optional, default 1) Column number of insertion start. Column numbering starts with 1.

###### Return value

Returns no value. If headerList is an empty list, an error is thrown.

###### Description

Insert row values from a Tcl list and format as a header row.

See also: SetRowValues FormatHeaderRow

#### SetHyperlink [::Excel]

Excel, Top

Insert a hyperlink into a cell.

SetHyperlink worksheetId row col link textDisplay

###### Parameters

worksheetId | Identifier of the worksheet the hyperlink is inserted to.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.
link | URL of the hyperlink.
textDisplay | (optional, default ) Text to be displayed instead of the URL.

###### Return value

Returns no value.

###### Description

Insert a hyperlink into a cell.

URL's are specified as strings: "file://myLinkedFile"; specifies a link to a local file. "http://myLinkedWebpage"; specifies a link to a web address.

See also: AddWorksheet SetHyperlinkToFile SetHyperlinkToCell SetLinkToCell

#### SetHyperlinkToCell [::Excel]

Excel, Top

Insert a hyperlink to a cell into another cell.

SetHyperlinkToCell srcWorksheetId srcRow srcCol destWorksheetId destRow destCol textDisplay

###### Parameters

srcWorksheetId | Identifier of the worksheet the link points to.
srcRow | Source row number. Row numbering starts with 1.
srcCol | Source column number. Column numbering starts with 1.
destWorksheetId | Identifier of the worksheet the link is inserted into.
destRow | Destination row number. Row numbering starts with 1.
destCol | Destination column number. Column numbering starts with 1.
textDisplay | (optional, default ) Text to be displayed instead of the hyperlink.

###### Return value

Returns no value.

###### Description

Insert a hyperlink to a cell into another cell.

See also: AddWorksheet SetHyperlinkToFile SetHyperlink SetLinkToCell

#### SetHyperlinkToFile [::Excel]

Excel, Top

Insert a hyperlink to a file into a cell.

SetHyperlinkToFile worksheetId row col fileName textDisplay

###### Parameters

worksheetId | Identifier of the worksheet the hyperlink is inserted to.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.
fileName | Path name of the linked file.
textDisplay | (optional, default ) Text to be displayed instead of the file name.

###### Return value

Returns no value.

###### Description

Insert a hyperlink to a file into a cell.

See also: AddWorksheet SetHyperlinkToCell SetHyperlink SetLinkToCell

#### SetLinkToCell [::Excel]

Excel, Top

Insert an internal link to a cell into another cell.

SetLinkToCell srcWorksheetId srcRow srcCol destWorksheetId destRow destCol

###### Parameters

srcWorksheetId | Identifier of the worksheet the link points to.
srcRow | Source row number. Row numbering starts with 1.
srcCol | Source column number. Column numbering starts with 1.
destWorksheetId | Identifier of the worksheet the link is inserted to.
destRow | Destination row number. Row numbering starts with 1.
destCol | Destination column number. Column numbering starts with 1.

###### Return value

Returns no value.

###### Description

Insert an internal link to a cell into another cell.

Note, that the number format of the source cell is used as number format of the destination cell.

See also: SetHyperlinkToCell SetHyperlinkToFile SetHyperlink

#### SetMatrixValues [::Excel]

Excel, Top

Insert matrix values into a worksheet.

SetMatrixValues worksheetId matrixList startRow startCol

###### Parameters

worksheetId | Identifier of the worksheet.
matrixList | Matrix with table data.
startRow | (optional, default 1) Row number of insertion start. Row numbering starts with 1.
startCol | (optional, default 1) Column number of insertion start. Column numbering starts with 1.

###### Return value

Returns no value.

###### Description

Insert matrix values into a worksheet.

The matrix data must be stored as a list of lists. Each sub-list contains the values for the row values. The main (outer) list contains the rows of the matrix.

Example:

        { { R1_C1 R1_C2 R1_C3 } { R2_C1 R2_C2 R2_C3 } }

See also: GetMatrixValues SetRowValues SetColumnValues

#### SetNamedRange [::Excel]

Excel, Top

Set the name of a cell range.

SetNamedRange rangeId rangeName useWorksheet

###### Parameters

rangeId | Identifier of the cell range.
rangeName | Name of the cell range. Must not contain spaces.
useWorksheet | (optional, default true) If true, set the name at the worksheet level. Otherwise set it at the workbook level.

###### Return value

Returns no value.

###### Description

Set the name of a cell range.

See also: GetNamedRange GetNamedRangeNames

#### SetRangeBorder [::Excel]

Excel, Top

Set the attributes of one border of a cell range.

SetRangeBorder rangeId side weight lineStyle args

###### Parameters

rangeId | Identifier of the cell range.
side | Value of enumeration type XlBordersIndex (see excelConst.tcl). Typical values: xlEdgeLeft, xlEdgeTop, xlEdgeBottom, xlEdgeRight.
weight | (optional, default xlThin) Value of enumeration type XlBorderWeight (see excelConst.tcl). Typical values: xlThin, xlMedium, xlThick.
lineStyle | (optional, default xlContinuous) Value of enumeration type XlLineStyle (see excelConst.tcl). Typical values: xlContinuous, xlDash, xlDot.
args | Border color.

###### Return value

Returns no value.

###### Description

Set the attributes of one border of a cell range.

Color value may be specified in a format acceptable by procedure ::Cawt::GetColor, i.e. color name, hexadecimal string, Office color number or a list of 3 integer RGB values. If no border color is specified, it is set to black.

See also: SetRangeBorders SelectRangeByIndex SelectRangeByString ::Cawt::GetColor

#### SetRangeBorders [::Excel]

Excel, Top

Set the attributes of all borders of a cell range.

SetRangeBorders rangeId weight lineStyle r g b

###### Parameters

rangeId | Identifier of the cell range.
weight | (optional, default xlThin) Value of enumeration type XlBorderWeight (see excelConst.tcl). Typical values: xlThin, xlMedium, xlThick.
lineStyle | (optional, default xlContinuous) Value of enumeration type XlLineStyle (see excelConst.tcl). Typical values: xlContinuous, xlDash, xlDot.
r | (optional, default 0) Red component of the border color.
g | (optional, default 0) Green component of the border color.
b | (optional, default 0) Blue component of the border color.

###### Return value

Returns no value.

###### Description

Set the attributes of all borders of a cell range.

The r, g and b values are specified as integers in the range [0, 255].

See also: SetRangeBorder SelectRangeByIndex SelectRangeByString

#### SetRangeComment [::Excel]

Excel, Top

Set the comment text of a cell range.

SetRangeComment rangeId comment imgFileName addUserName visible

###### Parameters

rangeId | Identifier of the cell range.
comment | Comment text.
imgFileName | (optional, default ) File name of an image used as comment background.
addUserName | (optional, default true) Automatically add user name before comment text.
visible | (optional, default false) true: Show the comment window. false: Hide the comment window.

###### Description

Set the comment text of a cell range.

Note, that an already existing comment is overwritten.

A comment may be used as a mouse-over tooltip, if parameter showComments of SetCommentDisplayMode is set to false. For a selection tooltip, use SetRangeTooltip.

Return the comment identifier.

See also: SetCommentDisplayMode SetCommentSize GetCellComment SelectRangeByIndex SelectRangeByString SetRangeTooltip ::Office::GetUserName

#### SetRangeFillColor [::Excel]

Excel, Top

Set the fill color of a cell range.

SetRangeFillColor rangeId args

###### Parameters

rangeId | Identifier of the cell range.
args | Background fill color.

###### Return value

Returns no value.

###### Description

Set the fill color of a cell range.

Color value may be specified in a format acceptable by procedure ::Cawt::GetColor, i.e. color name, hexadecimal string, Office color number or a list of 3 integer RGB values.

See also: SetRangeTextColor ::Cawt::GetColor SelectRangeByIndex SelectRangeByString

#### SetRangeFontBold [::Excel]

Excel, Top

Set the bold font style of a cell range.

SetRangeFontBold rangeId onOff

###### Parameters

rangeId | Identifier of the cell range.
onOff | (optional, default true) true: Set bold style on. false: Set bold style off.

###### Return value

Returns no value.

###### Description

Set the bold font style of a cell range.

See also: SetRangeFontName SetRangeFontItalic SetRangeFontUnderline SetRangeFontSize SelectRangeByIndex

#### SetRangeFontItalic [::Excel]

Excel, Top

Set the italic font style of a cell range.

SetRangeFontItalic rangeId onOff

###### Parameters

rangeId | Identifier of the cell range.
onOff | (optional, default true) true: Set italic style on. false: Set italic style off.

###### Return value

Returns no value.

###### Description

Set the italic font style of a cell range.

See also: SetRangeFontName SetRangeFontBold SetRangeFontUnderline SetRangeFontSize SelectRangeByIndex

#### SetRangeFontName [::Excel]

Excel, Top

Set the font name of a cell or character range.

SetRangeFontName rangeId fontName

###### Parameters

rangeId | Identifier of the cell range.
fontName | Name of the font as a string.

###### Return value

Returns no value.

###### Description

Set the font name of a cell or character range.

See also: SetRangeFontSubscript SetRangeFontSuperscript SetRangeFontBold SetRangeFontSize SelectRangeByIndex

#### SetRangeFontSize [::Excel]

Excel, Top

Set the font size of a cell range.

SetRangeFontSize rangeId size

###### Parameters

rangeId | Identifier of the cell range.
size | Font size.

###### Return value

Returns no value.

###### Description

Set the font size of a cell range.

The size value may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: SetRangeFontName SetRangeFontBold SetRangeFontItalic SetRangeFontUnderline SelectRangeByIndex ::Cawt::ValueToPoints

#### SetRangeFontSubscript [::Excel]

Excel, Top

Set the subscript font style of a cell or character range.

SetRangeFontSubscript rangeId onOff

###### Parameters

rangeId | Identifier of the cell range.
onOff | (optional, default true) true: Set subscript style on. false: Set subscript style off.

###### Return value

Returns no value.

###### Description

Set the subscript font style of a cell or character range.

See also: SetRangeFontName SetRangeFontSuperscript SelectRangeByIndex

#### SetRangeFontSuperscript [::Excel]

Excel, Top

Set the superscript font style of a cell or character range.

SetRangeFontSuperscript rangeId onOff

###### Parameters

rangeId | Identifier of the cell range.
onOff | (optional, default true) true: Set superscript style on. false: Set superscript style off.

###### Return value

Returns no value.

###### Description

Set the superscript font style of a cell or character range.

See also: SetRangeFontName SetRangeFontSubscript SelectRangeByIndex GetRangeCharacters

#### SetRangeFontUnderline [::Excel]

Excel, Top

Set the underline font style of a cell range.

SetRangeFontUnderline rangeId style

###### Parameters

rangeId | Identifier of the cell range.
style | (optional, default xlUnderlineStyleSingle) Value of enumeration type XlUnderlineStyle (see excelConst.tcl).

###### Return value

Returns no value.

###### Description

Set the underline font style of a cell range.

See also: SetRangeFontName SetRangeFontBold SetRangeFontItalic SetRangeFontSize SelectRangeByIndex

#### SetRangeFormat [::Excel]

Excel, Top

Set the number format of a cell range.

SetRangeFormat rangeId fmt subFmt

###### Parameters

rangeId | Identifier of the cell range.
fmt | Format of the cell range. Possible values: "text", "int", "real".
subFmt | (optional, default ) Sub-format of the cell range. Only valid, if fmt is "real". Then it specifies the number of digits before and after the decimal point. Use the GetNumberFormat procedure for specifying the sub-format. If subFmt is the empty string 2 digits after the decimal point are used.

###### Return value

Returns no value.

###### Description

Set the number format of a cell range.

If parameter fmt is not any of the predefined values, it is interpreted as a custom number format specified in Excel style.

See also: GetRangeFormat SelectRangeByIndex SelectRangeByString

#### SetRangeHorizontalAlignment [::Excel]

Excel, Top

Set the horizontal alignment of a cell range.

SetRangeHorizontalAlignment rangeId align

###### Parameters

rangeId | Identifier of the cell range.
align | Value of enumeration type XlHAlign (see excelConst.tcl).

###### Return value

Returns no value.

###### Description

Set the horizontal alignment of a cell range.

See also: GetRangeHorizontalAlignment SetRangeVerticalAlignment SelectRangeByIndex SelectRangeByString

#### SetRangeMergeCells [::Excel]

Excel, Top

Merge/Unmerge a range of cells.

SetRangeMergeCells rangeId onOff

###### Parameters

rangeId | Identifier of the cell range.
onOff | (optional, default true) true: Set cell merge on. false: Set cell merge off.

###### Return value

Returns no value.

###### Description

Merge/Unmerge a range of cells.

See also: SetRangeVerticalAlignment SelectRangeByIndex SelectRangeByString

#### SetRangeTextColor [::Excel]

Excel, Top

Set the text color of a cell range.

SetRangeTextColor rangeId args

###### Parameters

rangeId | Identifier of the cell range.
args | Text color.

###### Return value

Returns no value.

###### Description

Set the text color of a cell range.

Color value may be specified in a format acceptable by procedure ::Cawt::GetColor, i.e. color name, hexadecimal string, Office color number or a list of 3 integer RGB values.

See also: SetRangeFillColor ::Cawt::GetColor SelectRangeByIndex SelectRangeByString

#### SetRangeTooltip [::Excel]

Excel, Top

Set a selection based tooltip for a cell range.

SetRangeTooltip rangeId tooltipMessage tooltipTitle

###### Parameters

rangeId | Identifier of the cell range.
tooltipMessage | The tooltip message string.
tooltipTitle | (optional, default ) The optional tooltip title string.

###### Description

Set a selection based tooltip for a cell range.

The tooltip will be shown, if the cell is selected by the user. It is implemented by using the data validation functionality of Excel. If a mouse-over tooltip is needed, use SetRangeComment.

Return the validation identifier.

See also: SelectRangeByIndex SelectRangeByString SetRangeComment

#### SetRangeValues [::Excel]

Excel, Top

Set range values from a matrix.

SetRangeValues rangeId matrixList

###### Parameters

rangeId | Identifier of the cell range.
matrixList | Matrix with table data.

###### Return value

Returns no value.

###### Description

Set range values from a matrix.

The matrix data must be stored as a list of lists. Each sub-list contains the values for the row values. The main (outer) list contains the rows of the matrix.

Example:

        { { R1_C1 R1_C2 R1_C3 } { R2_C1 R2_C2 R2_C3 } }

See also: GetRangeValues SetMatrixValues SetRowValues SetColumnValues SetCellValue

#### SetRangeVerticalAlignment [::Excel]

Excel, Top

Set the vertical alignment of a cell range.

SetRangeVerticalAlignment rangeId align

###### Parameters

rangeId | Identifier of the cell range.
align | Value of enumeration type XlVAlign (see excelConst.tcl).

###### Return value

Returns no value.

###### Description

Set the vertical alignment of a cell range.

See also: SetRangeHorizontalAlignment SelectRangeByIndex SelectRangeByString

#### SetRangeWrapText [::Excel]

Excel, Top

Set the text wrapping mode of a cell range.

SetRangeWrapText rangeId onOff

###### Parameters

rangeId | Identifier of the cell range.
onOff | (optional, default true) true: Set text wrapping on. false: Set text wrapping off.

###### Return value

Returns no value.

###### Description

Set the text wrapping mode of a cell range.

See also: GetRangeWrapText SetRangeHorizontalAlignment SetRangeTextColor SelectRangeByIndex

#### SetRowHeight [::Excel]

Excel, Top

Set the height of a row.

SetRowHeight worksheetId row height

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.
height | (optional, default 0) A positive value specifies the row's height. A value of zero specifies that the rows's height fits automatically the height of all elements in the row.

###### Return value

Returns no value.

###### Description

Set the height of a row.

The height value may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: SetRowsHeight SetColumnWidth ColumnCharToInt ::Cawt::ValueToPoints

#### SetRowsHeight [::Excel]

Excel, Top

Set the height of a range of rows.

SetRowsHeight worksheetId startRow endRow height

###### Parameters

worksheetId | Identifier of the worksheet.
startRow | Range start row number. Row numbering starts with 1.
endRow | Range end row number. Row numbering starts with 1.
height | (optional, default 0) A positive value specifies the row's height. A value of zero specifies that the rows's height fits automatically the height of all elements in the row.

###### Return value

Returns no value.

###### Description

Set the height of a range of rows.

The height value may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: SetRowHeight SetColumnsWidth ColumnCharToInt

#### SetRowValues [::Excel]

Excel, Top

Insert row values from a Tcl list.

SetRowValues worksheetId row valList startCol numVals

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.
valList | List of values to be inserted.
startCol | (optional, default 1) Column number of insertion start. Column numbering starts with 1.
numVals | (optional, default 0) Negative or zero: All list values are inserted. Positive: numVals columns are filled with the list values (starting at list index 0).

###### Return value

Returns no value. If valList is an empty list, an error is thrown.

###### Description

Insert row values from a Tcl list.

See also: GetRowValues SetColumnValues SetCellValue ColumnCharToInt

#### SetSeriesLineWidth [::Excel]

Excel, Top

Set the line width of a series.

SetSeriesLineWidth seriesId width

###### Parameters

seriesId | Identifier of the series.
width | Line width.

###### Return value

Returns no value.

###### Description

Set the line width of a series.

See also: GetChartNumSeries GetChartSeries AddSeriesTrendLine

#### SetTablelistHeader [::Excel]

Excel, Top

Insert header values into a tablelist.

SetTablelistHeader tableId headerList

###### Parameters

tableId |
headerList |

###### Return value

Returns no value.

###### Description

Insert header values into a tablelist.

tableId | Identifier of the tablelist.
headerList | List with table header data.

See also: TablelistToWorksheet WorksheetToTablelist SetTablelistValues GetTablelistHeader

#### SetTablelistValues [::Excel]

Excel, Top

Insert matrix values into a tablelist.

SetTablelistValues tableId matrixList

###### Parameters

tableId |
matrixList |

###### Return value

Returns no value.

###### Description

Insert matrix values into a tablelist.

tableId | Identifier of the tablelist.
matrixList | Matrix with table data.

See also: TablelistToWorksheet WorksheetToTablelist SetTablelistHeader GetTablelistValues

#### SetWindowState [::Excel]

Excel, Top

Set the window state of an Excel application.

SetWindowState appId windowState

###### Parameters

appId | Identifier of the Excel instance.
windowState | (optional, default xlNormal) Value of enumeration type XlWindowState (see excelConst.tcl). Typical values are: xlMaximized, xlMinimized, xlNormal.

###### Return value

Returns no value.

###### Description

Set the window state of an Excel application.

See also: Open Visible ArrangeWindows

#### SetWorksheetFitToPages [::Excel]

Excel, Top

Adjust a worksheet to fit onto given number of pages.

SetWorksheetFitToPages worksheetId wide tall

###### Parameters

worksheetId | Identifier of the worksheet.
wide | (optional, default 1) The number of pages in horizontal direction.
tall | (optional, default 1) The number of pages in vertical direction.

###### Return value

Returns no value.

###### Description

Adjust a worksheet to fit onto given number of pages.

Use zero for parameters wide or tall to automatically determine the number of pages. When using the default values for wide and tall, the worksheet is adjusted to fit onto exactly one piece of paper.

See also: SetWorksheetOrientation SetWorksheetZoom SetWorksheetPrintOptions SetWorksheetPaperSize SetWorksheetMargins SetWorksheetHeader SetWorksheetFooter

#### SetWorksheetFooter [::Excel]

Excel, Top

Set the texts of the footer of a worksheet.

SetWorksheetFooter worksheetId args

###### Parameters

worksheetId | Identifier of the worksheet.
args | List of key value pairs specifying the footer text configure options and its values.

###### Return value

Returns no value.

###### Description

Set the texts of the footer of a worksheet.

Option keys:

-left

          Set the text of the left footer.

-center

          Set the text of the center footer.

-right

          Set the text of the right footer.

See also: SetWorksheetOrientation SetWorksheetFitToPages SetWorksheetZoom SetWorksheetPrintOptions SetWorksheetPaperSize SetWorksheetHeader SetWorksheetFooter

#### SetWorksheetHeader [::Excel]

Excel, Top

Set the texts of the header of a worksheet.

SetWorksheetHeader worksheetId args

###### Parameters

worksheetId | Identifier of the worksheet.
args | List of key value pairs specifying the header text configure options and its values.

###### Return value

Returns no value.

###### Description

Set the texts of the header of a worksheet.

Option keys:

-left

          Set the text of the left header.

-center

          Set the text of the center header.

-right

          Set the text of the right header.

See also: SetWorksheetOrientation SetWorksheetFitToPages SetWorksheetZoom SetWorksheetPrintOptions SetWorksheetPaperSize SetWorksheetHeader SetWorksheetFooter

#### SetWorksheetMargins [::Excel]

Excel, Top

Set the margins of a worksheet.

SetWorksheetMargins worksheetId args

###### Parameters

worksheetId | Identifier of the worksheet.
args | List of key value pairs specifying the margins configure options and its values.

###### Return value

Returns no value.

###### Description

Set the margins of a worksheet.

Option keys:

-top

          Set the size of the top margin.

-bottom

          Set the size of the bottom margin.

-left

          Set the size of the left margin.

-right

          Set the size of the right margin.

-footer

          Set the size of the footer margin.

-header

          Set the size of the header margin.

The margin values may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

Example:

        SetWorksheetMargins $worksheetId -top 1.5c -left 2i
        sets the top margin to 1.5 centimeters and the left margin to 2 inches.

See also: SetWorksheetOrientation SetWorksheetFitToPages SetWorksheetZoom SetWorksheetPrintOptions SetWorksheetPaperSize SetWorksheetHeader SetWorksheetFooter ::Cawt::ValueToPoints

#### SetWorksheetName [::Excel]

Excel, Top

Set the name of a worksheet.

SetWorksheetName worksheetId name

###### Parameters

worksheetId | Identifier of the worksheet.
name | Name of the worksheet.

###### Return value

Returns no value.

###### Description

Set the name of a worksheet.

See also: GetWorksheetName AddWorksheet

#### SetWorksheetOrientation [::Excel]

Excel, Top

Set the orientation of a worksheet.

SetWorksheetOrientation worksheetId orientation

###### Parameters

worksheetId | Identifier of the worksheet.
orientation | Value of enumeration type XlPageOrientation (see excelConst.tcl). Possible values: xlLandscape or xlPortrait.

###### Return value

Returns no value.

###### Description

Set the orientation of a worksheet.

See also: SetWorksheetFitToPages SetWorksheetZoom SetWorksheetPrintOptions SetWorksheetPaperSize SetWorksheetMargins SetWorksheetHeader SetWorksheetFooter

#### SetWorksheetPaperSize [::Excel]

Excel, Top

Set the paper size of a worksheet.

SetWorksheetPaperSize worksheetId paperSize

###### Parameters

worksheetId | Identifier of the worksheet.
paperSize | Value of enumeration type XlPaperSize (see excelConst.tcl).

###### Return value

Returns no value.

###### Description

Set the paper size of a worksheet.

See also: SetWorksheetOrientation SetWorksheetFitToPages SetWorksheetZoom SetWorksheetPrintOptions SetWorksheetMargins SetWorksheetHeader SetWorksheetFooter

#### SetWorksheetPrintOptions [::Excel]

Excel, Top

Set printing options of a worksheet.

SetWorksheetPrintOptions worksheetId args

###### Parameters

worksheetId | Identifier of the worksheet.
args | List of key value pairs specifying the print configure options and its values.

###### Return value

Returns no value.

###### Description

Set printing options of a worksheet.

Option keys:

-gridlines

          Set the printing of grid lines. Value is of type bool.

-bw

          Set printing in black-white only. Value is of type bool.

-draft

          Set printing quality to draft mode. Value is of type bool.

-headings

          Set printing of headings. Value is of type bool.

-comments

          Set printing of comments.
          Value is of enumeration type XlPrintLocation (see excelConst.tcl).
          Typical values: xlPrintInPlace, xlPrintNoComments.

-errors

          Set printing of errors.
          Value is of enumeration type XlPrintErrors (see excelConst.tcl).
          Typical values: xlPrintErrorsDisplayed, xlPrintErrorsBlank.

See also: SetWorksheetOrientation SetWorksheetFitToPages SetWorksheetZoom SetWorksheetPaperSize SetWorksheetMargins SetWorksheetHeader SetWorksheetFooter

#### SetWorksheetTabColor [::Excel]

Excel, Top

Set the color of the tab of a worksheet.

SetWorksheetTabColor worksheetId args

###### Parameters

worksheetId | Identifier of the worksheet.
args | Tab color.

###### Return value

Returns no value.

###### Description

Set the color of the tab of a worksheet.

Color value may be specified in a format acceptable by procedure ::Cawt::GetColor, i.e. color name, hexadecimal string, Office color number or a list of 3 integer RGB values.

See also: SetRangeTextColor ::Cawt::GetColor GetWorksheetIdByIndex

#### SetWorksheetZoom [::Excel]

Excel, Top

Set the zoom factor for printing of a worksheet.

SetWorksheetZoom worksheetId zoom

###### Parameters

worksheetId | Identifier of the worksheet.
zoom | (optional, default 100) The zoom factor in percent as an integer value.

###### Return value

Returns no value.

###### Description

Set the zoom factor for printing of a worksheet.

Valid zoom values are in the range [10, 400].

See also: SetWorksheetOrientation SetWorksheetFitToPages SetWorksheetPrintOptions SetWorksheetPaperSize SetWorksheetMargins SetWorksheetHeader SetWorksheetFooter

#### ShowAlerts [::Excel]

Excel, Top

Toggle the display of Excel application alerts.

ShowAlerts appId onOff

###### Parameters

appId | The application identifier.
onOff | Switch the alerts on or off.

###### Return value

Returns no value.

###### Description

Toggle the display of Excel application alerts.

#### ShowCellByIndex [::Excel]

Excel, Top

Show a cell identified by its row/column index.

ShowCellByIndex worksheetId row col

###### Parameters

worksheetId | Identifier of the worksheet.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.

###### Description

Show a cell identified by its row/column index.

Set the scrolling, so that the cell is show at the upper left corner.

See also: SelectCellByIndex

#### ShowWorksheet [::Excel]

Excel, Top

Show a worksheet.

ShowWorksheet worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Description

Show a worksheet.

See also: GetNumWorksheets GetWorksheetIdByName AddWorksheet

#### TablelistToWorksheet [::Excel]

Excel, Top

Insert the values of a tablelist into a worksheet.

TablelistToWorksheet tableId worksheetId useHeader startRow

###### Parameters

tableId | Identifier of the tablelist.
worksheetId | Identifier of the worksheet.
useHeader | (optional, default true) true: Insert the header of the tablelist as first row. false: Only transfer the tablelist data.
startRow | (optional, default 1) Row number of insertion start. Row numbering starts with 1.

###### Return value

Returns no value.

###### Description

Insert the values of a tablelist into a worksheet.

Note: The contents of hidden columns are transfered to Excel and are hidden there, too.

          If the tablelist contains a column with automatic line numbering, this column is
          transfered to Excel, too. If this behaviour is not wished, use the DeleteColumn
          procedure to delete the corresponding column in Excel.

See also: WorksheetToTablelist SetMatrixValues WikitFileToWorksheet MediaWikiFileToWorksheet MatlabFileToWorksheet RawImageFileToWorksheet WordTableToWorksheet

#### ToggleAutoFilter [::Excel]

Excel, Top

Toggle the AutoFilter switch of a cell range.

ToggleAutoFilter rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Return value

Returns no value.

###### Description

Toggle the AutoFilter switch of a cell range.

See also: SelectRangeByIndex SelectRangeByString

#### UnhideWorksheet [::Excel]

Excel, Top

Unhide a worksheet, if it is hidden.

UnhideWorksheet worksheetId

###### Parameters

worksheetId | Identifier of the worksheet.

###### Return value

Returns no value.

###### Description

Unhide a worksheet, if it is hidden.

If the worksheet is hidden, it is made visible.

See also: SetWorksheetTabColor IsWorksheetVisible

#### UseImgTransparency [::Excel]

Excel, Top

Toggle usage of transparency channel of an image.

UseImgTransparency onOff

###### Parameters

onOff |

###### Description

Toggle usage of transparency channel of an image.

Only valid for ImgToWorksheet and WorksheetToImg procedures.

See also: ImgToWorksheet WorksheetToImg

#### Visible [::Excel]

Excel, Top

Set or query the visibility of an Excel application window.

Visible appId visible

###### Parameters

appId | Identifier of the Excel instance.
visible | (optional, default ) true: Show the application window. false: Hide the application window. empty: Return the visbility status.

###### Description

Set or query the visibility of an Excel application window.

If parameter visible is not set or the empty string, the visibility status is returned as a boolean value. Otherwise no return value.

See also: Open OpenNew SetWindowState ArrangeWindows

#### WikitFileToExcelFile [::Excel]

Excel, Top

Convert a Wikit table file to an Excel file.

WikitFileToExcelFile wikiFileName excelFileName useHeader quitExcel

###### Parameters

wikiFileName | Name of the Wikit input file.
excelFileName | Name of the Excel output file.
useHeader | (optional, default true) true: Use header information from the Wikit file to generate an Excel header (see SetHeaderRow). false: Only transfer the table data.
quitExcel | (optional, default true) true: Quit the Excel instance after generation of output file. false: Leave the Excel instance open after generation of output file.

###### Description

Convert a Wikit table file to an Excel file.

The table data from the Wikit file will be inserted into a worksheet named "Wikit".

Return the Excel application identifier, if quitExcel is false. Otherwise no return value.

See also: WikitFileToWorksheet ExcelFileToWikitFile ReadWikitFile MediaWikiFileToExcelFile

#### WikitFileToWorksheet [::Excel]

Excel, Top

Insert the values of a Wikit table file into a worksheet.

WikitFileToWorksheet wikiFileName worksheetId useHeader

###### Parameters

wikiFileName | Name of the Wikit file.
worksheetId | Identifier of the worksheet.
useHeader | (optional, default true) true: Insert the header of the Wikit table as first row. false: Only transfer the table data.

###### Return value

Returns no value.

###### Description

Insert the values of a Wikit table file into a worksheet.

The insertion starts at row and column 1. Values contained in the worksheet cells are overwritten.

See also: WorksheetToWikitFile SetMatrixValues MediaWikiFileToWorksheet WordTableToWorksheet MatlabFileToWorksheet RawImageFileToWorksheet TablelistToWorksheet

#### WordTableToWorksheet [::Excel]

Excel, Top

Insert the values of a Word table into a worksheet.

WordTableToWorksheet tableId worksheetId useHeader

###### Parameters

tableId | Identifier of the Word table.
worksheetId | Identifier of the worksheet.
useHeader | (optional, default true) true: Insert the header of the Word table as first row. false: Only transfer the table data.

###### Return value

Returns no value.

###### Description

Insert the values of a Word table into a worksheet.

See also: WorksheetToWordTable SetMatrixValues WikitFileToWorksheet MediaWikiFileToWorksheet MatlabFileToWorksheet RawImageFileToWorksheet TablelistToWorksheet

#### WorksheetToClipboard [::Excel]

Excel, Top

Copy worksheet data into the clipboard.

WorksheetToClipboard worksheetId row1 col1 row2 col2 sepChar

###### Parameters

worksheetId | Identifier of the worksheet.
row1 | Row number of upper-left corner of the copy range.
col1 | Column number of upper-left corner of the copy range.
row2 | Row number of lower-right corner of the copy range.
col2 | Column number of lower-right corner of the copy range.
sepChar | (optional, default ;) The separation character of the clipboard matrix data.

###### Return value

Returns no value.

###### Description

Copy worksheet data into the clipboard.

The clipboard data will be in CSV format with sepChar as separation character.

See also: ClipboardToWorksheet MatrixToClipboard

#### WorksheetToHtmlFile [::Excel]

Excel, Top

Write the values of a worksheet into a HTML table file.

WorksheetToHtmlFile worksheetId htmlFileName useTarget

###### Parameters

worksheetId | Identifier of the worksheet.
htmlFileName | Name of the HTML file.
useTarget | (optional, default true) true: Generate a target attribute for hyperlinks. false: No target attribute for hyperlinks, i.e. link opens in same tab.

###### Return value

Returns no value.

###### Description

Write the values of a worksheet into a HTML table file.

The following attributes are exported to the HTML file: Font: Name, size, style (bold, italic, underline). Column span across a row. Text and background color. Horizontal and vertical text alignment. Hyperlinks.

See also: GetMatrixValues ExcelFileToHtmlFile WorksheetToMediaWikiFile WorksheetToWikitFile WorksheetToWordTable WorksheetToMatlabFile WorksheetToRawImageFile WorksheetToTablelist

#### WorksheetToImg [::Excel]

Excel, Top

Put worksheet background colors into a photo image.

WorksheetToImg worksheetId startRow startCol endRow endCol

###### Parameters

worksheetId | Identifier of the worksheet.
startRow | (optional, default 1) Row number of the top-left corner of the image.
startCol | (optional, default 1) Column number of the top-left corner of the image.
endRow | (optional, default end) Row number of the bottom-right corner of the image.
endCol | (optional, default end) Column number of the bottom-right corner of the image.

###### Description

Put worksheet background colors into a photo image.

Note: Row and column numbering starts with 1.

          Instead of using the number for endRow or endCol, it is possible to use
          the special word "end" to use the last used row or column.

Return the photo image identifier.

See also: ImgToWorksheet UseImgTransparency ::Cawt::ImgToClipboard RawImageFileToWorksheet GetLastUsedRow GetLastUsedColumn

#### WorksheetToMatlabFile [::Excel]

Excel, Top

Insert the values of a worksheet into a Matlab file.

WorksheetToMatlabFile worksheetId matFileName useHeader

###### Parameters

worksheetId | Identifier of the worksheet.
matFileName | Name of the Matlab file.
useHeader | (optional, default true) true: Interpret the first row of the worksheet as header and thus do not transfer this row into the Matlab file. false: All worksheet cells are interpreted as data.

###### Return value

Returns no value.

###### Description

Insert the values of a worksheet into a Matlab file.

Note: Only Matlab Level 4 files are currently supported.

See also: MatlabFileToWorksheet GetMatrixValues WorksheetToWikitFile WorksheetToMediaWikiFile WorksheetToRawImageFile WorksheetToTablelist WorksheetToWordTable

#### WorksheetToMediaWikiFile [::Excel]

Excel, Top

Insert the values of a worksheet into a MediaWiki table file.

WorksheetToMediaWikiFile worksheetId wikiFileName useHeader

###### Parameters

worksheetId | Identifier of the worksheet.
wikiFileName | Name of the MediaWiki file.
useHeader | (optional, default true) true: Use the first row of the worksheet as the header of the MediaWiki table. false: Do not generate a MediaWiki table header. All worksheet cells are interpreted as data.

###### Return value

Returns no value.

###### Description

Insert the values of a worksheet into a MediaWiki table file.

See also: MediaWikiFileToWorksheet GetMatrixValues WorksheetToWikitFile WorksheetToWordTable WorksheetToMatlabFile WorksheetToRawImageFile WorksheetToTablelist

#### WorksheetToRawImageFile [::Excel]

Excel, Top

Insert the values of a worksheet into a raw photo image file.

WorksheetToRawImageFile worksheetId rawFileName useHeader pixelType

###### Parameters

worksheetId | Identifier of the worksheet.
rawFileName | File name of the image.
useHeader | (optional, default true) true: Interpret the first row of the worksheet as header and thus do not transfer this row into the image. false: All worksheet cells are interpreted as data.
pixelType | (optional, default float) Pixel type (byte, short, float).

###### Return value

Returns no value.

###### Description

Insert the values of a worksheet into a raw photo image file.

The image generated is a 1-channel floating point photo image. It can be read and manipulated with the Img extension. It is not a "raw" image as used with digital cameras, but just "raw" image data.

See also: RawImageFileToWorksheet GetMatrixValues WorksheetToWikitFile WorksheetToMediaWikiFile WorksheetToMatlabFile WorksheetToTablelist WorksheetToWordTable

#### WorksheetToTablelist [::Excel]

Excel, Top

Insert the values of a worksheet into a tablelist.

WorksheetToTablelist worksheetId tableId useHeader

###### Parameters

worksheetId | Identifier of the worksheet.
tableId | Identifier of the tablelist.
useHeader | (optional, default true) true: Use the first row of the worksheet as the header of the tablelist. false: Do not generate a tablelist header. All worksheet cells are interpreted as data.

###### Return value

Returns no value.

###### Description

Insert the values of a worksheet into a tablelist.

Note: The contents of hidden columns are transfered from Excel to the tablelist

          and are hidden there, too.

See also: TablelistToWorksheet GetMatrixValues WorksheetToWikitFile WorksheetToMediaWikiFile WorksheetToMatlabFile WorksheetToRawImageFile WorksheetToWordTable

#### WorksheetToWikitFile [::Excel]

Excel, Top

Insert the values of a worksheet into a Wikit table file.

WorksheetToWikitFile worksheetId wikiFileName useHeader

###### Parameters

worksheetId | Identifier of the worksheet.
wikiFileName | Name of the Wikit file.
useHeader | (optional, default true) true: Use the first row of the worksheet as the header of the Wikit table. false: Do not generate a Wikit table header. All worksheet cells are interpreted as data.

###### Return value

Returns no value.

###### Description

Insert the values of a worksheet into a Wikit table file.

See also: WikitFileToWorksheet GetMatrixValues WorksheetToMediaWikiFile WorksheetToWordTable WorksheetToMatlabFile WorksheetToRawImageFile WorksheetToTablelist

#### WorksheetToWordTable [::Excel]

Excel, Top

Insert the values of a worksheet into a Word table.

WorksheetToWordTable worksheetId tableId useHeader

###### Parameters

worksheetId | Identifier of the worksheet.
tableId | Identifier of the Word table.
useHeader | (optional, default true) true: Use the first row of the worksheet as the header of the Word table. false: Do not generate a Word table header. All worksheet cells are interpreted as data.

###### Return value

Returns no value.

###### Description

Insert the values of a worksheet into a Word table.

See also: WordTableToWorksheet GetMatrixValues WorksheetToWikitFile WorksheetToMediaWikiFile WorksheetToMatlabFile WorksheetToRawImageFile WorksheetToTablelist

#### WriteCsvFile [::Excel]

Excel, Top

Write the values of a matrix into a CSV file.

WriteCsvFile matrixList csvFileName

###### Parameters

matrixList | Matrix with table data.
csvFileName | Name of the CSV file.

###### Return value

Returns no value.

###### Description

Write the values of a matrix into a CSV file.

See SetMatrixValues for the description of a matrix representation.

See also: ReadCsvFile

#### WriteHtmlFile [::Excel]

Excel, Top

Write the values of a matrix into a Html table file.

WriteHtmlFile matrixList htmlFileName useHeader

###### Parameters

matrixList | Matrix with table data.
htmlFileName | Name of the HTML file.
useHeader | (optional, default true) true: Use first row of the matrix as header of the HTML table.

###### Return value

Returns no value.

###### Description

Write the values of a matrix into a Html table file.

See SetMatrixValues for the description of a matrix representation.

See also: WorksheetToHtmlFile

#### WriteMatlabFile [::Excel]

Excel, Top

Write the values of a matrix into a Matlab file.

WriteMatlabFile matrixList matFileName

###### Parameters

matrixList | Floating point matrix.
matFileName | Name of the Matlab file.

###### Return value

Returns no value.

###### Description

Write the values of a matrix into a Matlab file.

Note: Only Matlab Level 4 files are currently supported. See SetMatrixValues for the description of a matrix representation.

See also: ReadMatlabFile WorksheetToMatlabFile

#### WriteMediaWikiFile [::Excel]

Excel, Top

Write the values of a matrix into a MediaWiki table file.

WriteMediaWikiFile matrixList wikiFileName useHeader tableName

###### Parameters

matrixList | Matrix with table data.
wikiFileName | Name of the MediaWiki file.
useHeader | (optional, default true) true: Use first row of the matrix as header of the MediaWiki table. false: Only transfer the table data.
tableName | (optional, default ) Table name (caption) of the generated MediaWiki table.

###### Return value

Returns no value.

###### Description

Write the values of a matrix into a MediaWiki table file.

See SetMatrixValues for the description of a matrix representation.

See also: ReadMediaWikiFile WorksheetToMediaWikiFile

#### WriteRawImageFile [::Excel]

Excel, Top

Write the values of a matrix into a raw photo image file.

WriteRawImageFile matrixList rawImgFile pixelType

###### Parameters

matrixList | Floating point matrix.
rawImgFile | File name of the image.
pixelType | (optional, default float) Pixel type (byte, short, float).

###### Return value

Returns no value.

###### Description

Write the values of a matrix into a raw photo image file.

Note: The matrix values are written as 1-channel image with given pixel type.

See SetMatrixValues for the description of a matrix representation.

See also: ReadRawImageFile WorksheetToRawImageFile

#### WriteWikitFile [::Excel]

Excel, Top

Write the values of a matrix into a Wikit table file.

WriteWikitFile matrixList wikiFileName useHeader

###### Parameters

matrixList | Matrix with table data.
wikiFileName | Name of the Wikit file.
useHeader | (optional, default true) true: Use first row of the matrix as header of the Wikit table.

###### Return value

Returns no value.

###### Description

Write the values of a matrix into a Wikit table file.

See SetMatrixValues for the description of a matrix representation.

See also: ReadWikitFile WorksheetToWikitFile

# ::Explorer

## Introduction

The Explorer namespace provides commands to control the Internet Explorer browser.

Note: If running on Windows Vista or 7, you have to lower the security settings like follows:

Internet Options -> Security -> Trusted Sites : Low

Internet Options -> Security -> Internet : Medium + unchecked Enable Protected Mode

Internet Options -> Security -> Restricted Sites : unchecked Enable Protected Mode

## Commands

#### FullScreen [::Explorer]

Explorer, Top

Toggle the fullscreen mode of an Internet Explorer application window.

FullScreen appId onOff

###### Parameters

appId | Identifier of the Internet Explorer instance.
onOff | true: Use fullscreen mode. false: Use windowed mode.

###### Return value

Returns no value.

###### Description

Toggle the fullscreen mode of an Internet Explorer application window.

See also: Open Visible

#### Go [::Explorer]

Explorer, Top

Go to a specific page.

Go appId target

###### Parameters

appId | Identifier of the Internet Explorer instance.
target | String identifying the target page.

###### Return value

Returns no value.

###### Description

Go to a specific page.

Possible values for target are: "Back", "Forward", "Home", "Search"

#### IsBusy [::Explorer]

Explorer, Top

Check, if an Internet Explorer instance is busy.

IsBusy appId

###### Parameters

appId | Identifier of the Internet Explorer instance.

###### Description

Check, if an Internet Explorer instance is busy.

Return true or false dependent on the busy status.

#### Navigate [::Explorer]

Explorer, Top

Navigate to a URL or local file.

Navigate appId urlOrFile wait targetFrame

###### Parameters

appId | Identifier of the Internet Explorer instance.
urlOrFile | URL or local file name (as an absolute pathname).
wait | (optional, default true) Wait until page has been loaded completely.
targetFrame | (optional, default _self) Name of the frame in which to display the resource.

###### Return value

Returns no value.

###### Description

Navigate to a URL or local file.

The following predefined names for targetFrame are possible: "_blank": Load the link into a new unnamed window. "_parent": Load the link into the immediate parent of the document the link is in. "_self": Load the link into the same window the link was clicked in. "_top": Load the link into the full body of the current window.

If given any other string, it is interpreted as a named HTML frame. If no frame or window exists that matches the specified target name, a new window is opened for the specified link.

See also: Open OpenNew

#### Open [::Explorer]

Explorer, Top

Open an Internet Explorer instance. Use an already running instance, if available. Use an already running Internet Explorer, if available.

Open visible width height

###### Parameters

visible | (optional, default true) true: Show the application window. false: Hide the application window.
width | (optional, default -1) Width of the application window. If negative, open with last used width.
height | (optional, default -1) Height of the application window. If negative, open with last used height.

###### Description

Open an Internet Explorer instance. Use an already running instance, if available. Use an already running Internet Explorer, if available.

Return the identifier of the Internet Explorer application instance.

See also: OpenNew Quit Visible

#### OpenNew [::Explorer]

Explorer, Top

Open a new Internet Explorer instance.

OpenNew visible width height

###### Parameters

visible | (optional, default true) true: Show the application window. false: Hide the application window.
width | (optional, default -1) Width of the application window. If negative, open with last used width.
height | (optional, default -1) Height of the application window. If negative, open with last used height.

###### Description

Open a new Internet Explorer instance.

Return the identifier of the new Internet Explorer application instance.

See also: Open Quit Visible

#### Quit [::Explorer]

Explorer, Top

Quit an Internet Explorer instance.

Quit appId

###### Parameters

appId | Identifier of the Internet Explorer instance.

###### Return value

Returns no value.

###### Description

Quit an Internet Explorer instance.

See also: Open

#### Visible [::Explorer]

Explorer, Top

Toggle the visibility of an Internet Explorer application window.

Visible appId visible

###### Parameters

appId | Identifier of the Internet Explorer instance.
visible | true: Show the application window. false: Hide the application window.

###### Return value

Returns no value.

###### Description

Toggle the visibility of an Internet Explorer application window.

See also: Open OpenNew

# ::Matlab

## Introduction

The Matlab namespace provides commands to control MathWorks Matlab.

## Commands

#### ExecCmd [::Matlab]

Matlab, Top

Execute a Matlab command.

ExecCmd appId cmd

###### Parameters

appId | Identifier of the Matlab instance.
cmd | String containg the Matlab command being executed.

###### Description

Execute a Matlab command.

Return the Matlab answer as a string.

#### Open [::Matlab]

Matlab, Top

Open a Matlab instance. Use an already running instance, if available.

Open visible

###### Parameters

visible | (optional, default true) true: Show the application window. false: Hide the application window.

###### Description

Open a Matlab instance. Use an already running instance, if available.

Return the identifier of the Matlab application instance.

See also: OpenNew Visible Quit

#### OpenNew [::Matlab]

Matlab, Top

Open a new Matlab instance.

OpenNew visible

###### Parameters

visible | (optional, default true) true: Show the application window. false: Hide the application window.

###### Description

Open a new Matlab instance.

Return the identifier of the new Matlab application instance.

See also: Open Visible Quit

#### Quit [::Matlab]

Matlab, Top

Quit a Matlab instance.

Quit appId

###### Parameters

appId | Identifier of the Matlab instance.

###### Return value

Returns no value.

###### Description

Quit a Matlab instance.

See also: Open

#### Visible [::Matlab]

Matlab, Top

Toggle the visibility of a Matlab application window.

Visible appId visible

###### Parameters

appId | Identifier of the Matlab instance.
visible | true: Show the application window. false: Hide the application window.

###### Return value

Returns no value.

###### Description

Toggle the visibility of a Matlab application window.

See also: Open OpenNew

# ::Ocr

## Introduction

The Ocr namespace provides commands to control Microsoft Document Imaging.

## Commands

#### Close [::Ocr]

Ocr, Top

Close an OCR document instance.

Close docId

###### Parameters

docId | Identifier of the OCR document.

###### Return value

Returns no value.

###### Description

Close an OCR document instance.

See also: Open

#### GetFullText [::Ocr]

Ocr, Top

Return the recognized text of an OCR layout.

GetFullText layoutId

###### Parameters

layoutId | Identifier of the OCR layout.

###### Description

Return the recognized text of an OCR layout.

See also: Scan

#### GetNumImages [::Ocr]

Ocr, Top

Return the number of images of an OCR document.

GetNumImages docId

###### Parameters

docId | Identifier of the OCR document.

###### Description

Return the number of images of an OCR document.

See also: OpenDocument Scan

#### GetNumWords [::Ocr]

Ocr, Top

Return the number of words identified in an OCR document.

GetNumWords layoutId

###### Parameters

layoutId | Identifier of the OCR layout.

###### Description

Return the number of words identified in an OCR document.

See also: GetFullText GetNumImages Scan

#### GetWord [::Ocr]

Ocr, Top

Return the text of a recognized word.

GetWord layoutId wordNum

###### Parameters

layoutId | Identifier of the OCR layout.
wordNum | Index number of the word (starting at zero).

###### Description

Return the text of a recognized word.

See also: GetFullText GetNumWords Scan

#### GetWordStats [::Ocr]

Ocr, Top

Return statistics of a recognized word.

GetWordStats layoutId wordNum

###### Parameters

layoutId | Identifier of the OCR layout.
wordNum | Index number of the word (starting at zero).

###### Description

Return statistics of a recognized word.

The statistics is returned as a dictionary containing the following keys: Id, LineId, RegionId, FontId, Confidence.

See also: GetFullText GetWord Scan

#### Open [::Ocr]

Ocr, Top

Open an OCR document instance.

Open

###### Description

Open an OCR document instance.

Return the OCR document identifier.

See also: OpenDocument Close

#### OpenDocument [::Ocr]

Ocr, Top

Open an image file for OCR scanning.

OpenDocument docId fileName

###### Parameters

docId | OCR document identifier.
fileName | Image to be scanned. Must be in TIFF or BMP format.

###### Return value

Returns no value.

###### Description

Open an image file for OCR scanning.

See also: Open Close

#### Scan [::Ocr]

Ocr, Top

Scan an image.

Scan docId imgNum

###### Parameters

docId | Identifier of the OCR document.
imgNum | (optional, default 0) Image number to be scanned.

###### Description

Scan an image.

Return the layout identifier of the scanned image.

See also: OpenDocument GetNumImages

# ::Office

## Commands

#### ColorToRgb [::Office]

Office, Top

Obsolete: Replaced with ::Cawt::OfficeColorToRgb in version 2.2.0

ColorToRgb color

###### Parameters

color |

###### Description

Obsolete: Replaced with ::Cawt::OfficeColorToRgb in version 2.2.0

#### GetActivePrinter [::Office]

Office, Top

Get the name of the active printer.

GetActivePrinter appId

###### Parameters

appId | The application identifier.

###### Return value

Returns the name of the active printer as a string.

###### Description

Get the name of the active printer.

See also: SetPrinterCommunication

#### GetApplicationId [::Office]

Office, Top

Get the application identifier of an Office object.

GetApplicationId objId

###### Parameters

objId | The identifier of an Office object.

###### Return value

Returns the application identifier of the Office object.

###### Description

Get the application identifier of an Office object.

Office object are Workbooks, Worksheets, ...

See also: GetApplicationName IsApplicationId

#### GetApplicationName [::Office]

Office, Top

Get the name of an Office application.

GetApplicationName objId

###### Parameters

objId | The identifier of an Office object.

###### Return value

Returns the name of the application as a string.

###### Description

Get the name of an Office application.

See also: GetApplicationId IsApplicationId

#### GetApplicationVersion [::Office]

Office, Top

Get the version number of an Office application.

GetApplicationVersion objId

###### Parameters

objId | The identifier of an Office object.

###### Return value

Returns the version of the application as a floating point number.

###### Description

Get the version number of an Office application.

See also: GetApplicationId GetApplicationName

#### GetDocumentProperties [::Office]

Office, Top

Get document property names as a list.

GetDocumentProperties objId type

###### Parameters

objId | The identifier of an Office object (Workbook, Document, Presentation).
type | (optional, default ) Type of document properties ("Builtin" or "Custom"). If type is not specified or the empty string, both types of document properties are included in the list.

###### Return value

Returns a sorted Tcl list containing the names of all properties of the specified type.

###### Description

Get document property names as a list.

See also: GetDocumentProperty SetDocumentProperty

#### GetDocumentProperty [::Office]

Office, Top

Get the value of a document property.

GetDocumentProperty objId propertyName

###### Parameters

objId | The identifier of an Office object (Workbook, Document, Presentation).
propertyName | The name of the property.

###### Return value

Returns the value of specified property. If the property value is not set or an invalid property name is given, the string "N/A" is returned.

###### Description

Get the value of a document property.

See also: GetDocumentProperties SetDocumentProperty

#### GetEnum [::Office]

Office, Top

Get numeric value of an enumeration.

GetEnum enumOrString

###### Parameters

enumOrString | Enumeration name

###### Return value

Returns the numeric value of an enumeration.

###### Description

Get numeric value of an enumeration.

See also: GetEnumName GetEnumTypes GetEnumVal GetEnumNames

#### GetEnumName [::Office]

Office, Top

Get name of a given enumeration type and numeric value.

GetEnumName enumType enumVal

###### Parameters

enumType | Enumeration type
enumVal | Enumeration numeric value.

###### Return value

Returns a list of names of a given enumeration type.

###### Description

Get name of a given enumeration type and numeric value.

See also: GetEnumNames GetEnumTypes GetEnumVal GetEnum

#### GetEnumNames [::Office]

Office, Top

Get names of a given enumeration type.

GetEnumNames enumType

###### Parameters

enumType | Enumeration type

###### Return value

Returns a list of names of a given enumeration type.

###### Description

Get names of a given enumeration type.

See also: GetEnumName GetEnumTypes GetEnumVal GetEnum

#### GetEnumTypes [::Office]

Office, Top

Get available enumeration types.

GetEnumTypes

###### Return value

Returns a list of available enumeration types.

###### Description

Get available enumeration types.

See also: GetEnumName GetEnumNames GetEnumVal GetEnum

#### GetEnumVal [::Office]

Office, Top

Get numeric value of an enumeration name.

GetEnumVal enumName

###### Parameters

enumName | Enumeration name

###### Return value

Returns the numeric value of an enumeration name.

###### Description

Get numeric value of an enumeration name.

See also: GetEnumName GetEnumTypes GetEnumNames GetEnum

#### GetInstallationPath [::Office]

Office, Top

Get the Office installation pathname.

GetInstallationPath appId

###### Parameters

appId | The application identifier.

###### Return value

Returns the installation pathname as a string.

###### Description

Get the Office installation pathname.

#### GetOfficeType [::Office]

Office, Top

Get the Office type of a file.

GetOfficeType fileName

###### Parameters

fileName | File name.

###### Return value

Returns the Office type of the file. Possible values are: Excel, Ppt, Word. If the file is not an Office file, the return value is the empty string.

###### Description

Get the Office type of a file.

See also: ::Excel::GetExtString ::Ppt::GetExtString ::Word::GetExtString

#### GetStartupPath [::Office]

Office, Top

Get the Office startup pathname.

GetStartupPath appId

###### Parameters

appId | The application identifier.

###### Return value

Returns the startup pathname as a string.

###### Description

Get the Office startup pathname.

#### GetTemplatesPath [::Office]

Office, Top

Get the Office templates pathname.

GetTemplatesPath appId

###### Parameters

appId | The application identifier.

###### Return value

Returns the templates pathname as a string.

###### Description

Get the Office templates pathname.

#### GetUserLibraryPath [::Office]

Office, Top

Get the Office user library pathname.

GetUserLibraryPath appId

###### Parameters

appId | The application identifier.

###### Return value

Returns the user library pathname as a string.

###### Description

Get the Office user library pathname.

#### GetUserName [::Office]

Office, Top

Get the name of the Office application user.

GetUserName appId

###### Parameters

appId | The application identifier.

###### Return value

Returns the name of the application user as a string.

###### Description

Get the name of the Office application user.

#### GetUserPath [::Office]

Office, Top

Get the Office user folder's pathname.

GetUserPath appId

###### Parameters

appId | The application identifier.

###### Return value

Returns the user folder's pathname as a string.

###### Description

Get the Office user folder's pathname.

#### IsApplicationId [::Office]

Office, Top

Check, if Office object is an application identifier.

IsApplicationId objId

###### Parameters

objId | The identifier of an Office object.

###### Return value

Returns true, if objId is a valid Office application identifier. Otherwise return false.

###### Description

Check, if Office object is an application identifier.

See also: ::Cawt::IsComObject GetApplicationId GetApplicationName

#### RgbToColor [::Office]

Office, Top

Obsolete: Replaced with ::Cawt::RgbToOfficeColor in version 2.2.0

RgbToColor r g b

###### Parameters

r |
g |
b |

###### Description

Obsolete: Replaced with ::Cawt::RgbToOfficeColor in version 2.2.0

#### SetDocumentProperty [::Office]

Office, Top

Set the value of a document property.

SetDocumentProperty objId propertyName propertyValue

###### Parameters

objId | The identifier of an Office object (Workbook, Document, Presentation).
propertyName | The name of the property to set.
propertyValue | The value for the property as string.

###### Return value

Returns no value.

###### Description

Set the value of a document property.

If the property name is a builtin property, it's value is set. Otherwise either a new custom property is generated and it's value set or, if the custom property already exists, only it's value is set.

See also: GetDocumentProperties GetDocumentProperty

#### SetPrinterCommunication [::Office]

Office, Top

Enable or disable printer communication.

SetPrinterCommunication objId onOff

###### Parameters

objId | The identifier of an Office object.
onOff | true : Printer communication is enabled. false: Printer communication is disabled.

###### Return value

Returns no value.

###### Description

Enable or disable printer communication.

Disable the printer communication to speed up the execution of code that sets PageSetup properties, ex. SetWorksheetPrintOptions. Enable the printer communication after setting properties to commit all cached PageSetup commands.

Note: This method is only available in Office 2010 or newer.

See also: GetActivePrinter

#### ShowAlerts [::Office]

Office, Top

Obsolete: Replaced with module specific procedures in version 2.4.3

ShowAlerts appId onOff

###### Parameters

appId |
onOff |

###### Return value

Returns no value.

###### Description

Obsolete: Replaced with module specific procedures in version 2.4.3

Toggle the display of Office alerts.

appId | The application identifier.
onOff | Switch the alerts on or off.

# ::OneNote

## Introduction

The OneNote namespace provides commands to control Microsoft OneNote.

## Commands

#### FindNodeByName [::OneNote]

OneNote, Top

Get a specific node by name.

FindNodeByName domNode nodeType nodeName

###### Parameters

domNode | DOM node.
nodeType | Node type ("Notebook", "Section", "Page").
nodeName | Node name.

###### Description

Get a specific node by name.

See also: FindNotebook FindSection FindPage GetNodeName

#### FindNotebook [::OneNote]

OneNote, Top

Get a specific notebook by name.

FindNotebook domNode nodeName

###### Parameters

domNode | DOM root node as returned by GetDomRoot.
nodeName | Node name.

###### Description

Get a specific notebook by name.

See also: FindNodeByName FindSection FindPage GetDomRoot GetNodeName

#### FindPage [::OneNote]

OneNote, Top

Get a specific page by name.

FindPage domNode nodeName

###### Parameters

domNode | DOM node identifying a section.
nodeName | Node name.

###### Description

Get a specific page by name.

See also: FindNodeByName FindNotebook FindSection GetPages GetNodeName

#### FindSection [::OneNote]

OneNote, Top

Get a specific section by name.

FindSection domNode nodeName

###### Parameters

domNode | DOM node identifying a notebook.
nodeName | Node name.

###### Description

Get a specific section by name.

See also: FindNodeByName FindNotebook FindPage GetSections GetNodeName

#### GetApplicationId [::OneNote]

OneNote, Top

Get the application identifier of a OneNote object.

GetApplicationId oneNoteId

###### Parameters

oneNoteId | Identifier dict of a OneNote object.

###### Description

Get the application identifier of a OneNote object.

See also: Open GetDomId

#### GetDomId [::OneNote]

OneNote, Top

Get the DOM identifier of a OneNote object.

GetDomId oneNoteId

###### Parameters

oneNoteId | Identifier dict of a OneNote object.

###### Description

Get the DOM identifier of a OneNote object.

See also: Open GetApplicationId GetDomRoot

#### GetDomRoot [::OneNote]

OneNote, Top

Get the DOM root of a OneNote object.

GetDomRoot oneNoteId

###### Parameters

oneNoteId | Identifier dict of a OneNote object.

###### Description

Get the DOM root of a OneNote object.

See also: Open GetApplicationId GetDomId

#### GetEnum [::OneNote]

OneNote, Top

Get numeric value of an enumeration.

GetEnum enumOrString

###### Parameters

enumOrString | Enumeration name

###### Return value

Returns the numeric value of an enumeration.

###### Description

Get numeric value of an enumeration.

See also: GetEnumTypes GetEnumVal GetEnumNames

#### GetEnumNames [::OneNote]

OneNote, Top

Get names of a given enumeration type.

GetEnumNames enumType

###### Parameters

enumType | Enumeration type

###### Return value

Returns a list of names of a given enumeration type.

###### Description

Get names of a given enumeration type.

See also: GetEnumTypes GetEnumVal GetEnum

#### GetEnumTypes [::OneNote]

OneNote, Top

Get available enumeration types.

GetEnumTypes

###### Return value

Returns a list of available enumeration types.

###### Description

Get available enumeration types.

See also: GetEnumNames GetEnumVal GetEnum

#### GetEnumVal [::OneNote]

OneNote, Top

Get numeric value of an enumeration name.

GetEnumVal enumName

###### Parameters

enumName | Enumeration name

###### Return value

Returns the numeric value of an enumeration name.

###### Description

Get numeric value of an enumeration name.

See also: GetEnumTypes GetEnumNames GetEnum

#### GetExtString [::OneNote]

OneNote, Top

Return the default extension of a OneNote file.

GetExtString oneNoteId

###### Parameters

oneNoteId | Identifier dict of a OneNote object.

###### Return value

Returns the default extension of a OneNote file.

###### Description

Return the default extension of a OneNote file.

See also: Open GetVersion

#### GetLastModified [::OneNote]

OneNote, Top

Get nodes with specific modification date.

GetLastModified domNode compareDate nodeType notebookName

###### Parameters

domNode | DOM node.
compareDate | (optional, default 0) Date in seconds (as returned by clock seconds).
nodeType | (optional, default any) Node type ("any", "Notebook", "Section", "Page").
notebookName | (optional, default ) Notebook name.

###### Description

Get nodes with specific modification date.

See also: FindNotebook GetDomRoot

#### GetNodeAttribute [::OneNote]

OneNote, Top

Get attribute value of a DOM node.

GetNodeAttribute domNode attrName

###### Parameters

domNode | DOM node.
attrName | Attribute name.

###### Return value

Returns attribute value as string.

###### Description

Get attribute value of a DOM node.

See also: GetNodeName GetNodeHyperLink

#### GetNodeHyperLink [::OneNote]

OneNote, Top

Get hyperlink to OneNote node.

GetNodeHyperLink oneNoteId domNode

###### Parameters

oneNoteId | Identifier dict of a OneNote object.
domNode | DOM node.

###### Return value

Returns hyperlink as string.

###### Description

Get hyperlink to OneNote node.

See also: Open GetNodeAttribute GetNodeName

#### GetNodeName [::OneNote]

OneNote, Top

Get value of node attribute "name".

GetNodeName domNode

###### Parameters

domNode | DOM node.

###### Return value

Returns attribute value as string.

###### Description

Get value of node attribute "name".

See also: GetNodeAttribute GetNodeHyperLink

#### GetNodesByType [::OneNote]

OneNote, Top

Get nodes of specific type.

GetNodesByType domNode nodeType

###### Parameters

domNode | DOM node.
nodeType | Node type ("Notebook", "Section", "Page").

###### Description

Get nodes of specific type.

See also: GetNotebooks GetSections GetPages GetNodeType

#### GetNodeType [::OneNote]

OneNote, Top

Get type of a DOM node.

GetNodeType domNode

###### Parameters

domNode | DOM node.

###### Return value

Returns node type as string. Possible values: "Notebook", "Section", "Page".

###### Description

Get type of a DOM node.

See also: IsNodeType GetNodesByType

#### GetNotebooks [::OneNote]

OneNote, Top

Get the notebooks of a OneNote object.

GetNotebooks domNode

###### Parameters

domNode | DOM root node as returned by GetDomRoot.

###### Description

Get the notebooks of a OneNote object.

See also: GetNodesByType GetSections GetPages GetDomRoot GetNodeType

#### GetPageContent [::OneNote]

OneNote, Top

Get page content as XML.

GetPageContent oneNoteId domNode

###### Parameters

oneNoteId | Identifier dict of a OneNote object.
domNode | DOM node of a page.

###### Description

Get page content as XML.

See also: Open PrintPage

#### GetPages [::OneNote]

OneNote, Top

Get the pages of a OneNote section.

GetPages domNode

###### Parameters

domNode | DOM node identifying a section.

###### Description

Get the pages of a OneNote section.

See also: GetNodesByType GetSections GetPages FindSection GetNodeType

#### GetSections [::OneNote]

OneNote, Top

Get the sections of a OneNote notebook.

GetSections domNode

###### Parameters

domNode | DOM node identifying a notebook.

###### Description

Get the sections of a OneNote notebook.

See also: GetNodesByType GetNotebooks GetPages FindNotebook GetNodeType

#### GetVersion [::OneNote]

OneNote, Top

Return the version of a OneNote application.

GetVersion oneNoteId useString

###### Parameters

oneNoteId | Identifier dict of a OneNote object.
useString | (optional, default false) true: Return the version name (ex. "OneNote 2010"). false: Return the version number (ex. "12.0").

###### Return value

Returns the version of a OneNote application.

###### Description

Return the version of a OneNote application.

Both version name and version number are returned as strings. Version number is in a format, so that it can be evaluated as a floating point number.

See also: Open GetExtString

#### IsNodeType [::OneNote]

OneNote, Top

Check, if node is of specific type.

IsNodeType domNode nodeType

###### Parameters

domNode | DOM node.
nodeType | Node type ("Notebook", "Section", "Page").

###### Return value

Returns true, if node is of specified type. Otherwise false.

###### Description

Check, if node is of specific type.

See also: GetNodeType GetNodesByType

#### Open [::OneNote]

OneNote, Top

Open a OneNote instance.

Open

###### Return value

Returns the identifier of the OneNote instance.

###### Description

Open a OneNote instance.

The identifier is a dictionary containing 2 elements: Key appId: The application identifier. Key docId: The DOM node identifier.

See also: Quit GetApplicationId GetDomId

#### PrintPage [::OneNote]

OneNote, Top

Print page content as XML to standard output.

PrintPage oneNoteId domNode

###### Parameters

oneNoteId | Identifier dict of a OneNote object.
domNode | DOM node of a page.

###### Description

Print page content as XML to standard output.

See also: GetPageContent

#### Quit [::OneNote]

OneNote, Top

Quit a OneNote instance.

Quit oneNoteId

###### Parameters

oneNoteId | Identifier dict of a OneNote object.

###### Return value

Returns no value.

###### Description

Quit a OneNote instance.

See also: Open

# ::Outlook

## Introduction

The Outlook namespace provides commands to control Microsoft Outlook.

## Commands

#### AddAppointment [::Outlook]

Outlook, Top

Create a new appointment in an Outlook calendar.

AddAppointment calId args

###### Parameters

calId | Identifier of the Outlook calendar.
args | List of key value pairs specifying appointment configure options and its values.

###### Return value

Returns the identifier of the new appointment object.

###### Description

Create a new appointment in an Outlook calendar.

Option keys:

-subject <string>

          Set the subject text of the appointment.
          Default: No subject.

-startdate <string>

          Set the start date of the appointment in format "%Y-%m-%d %H:%M:%S".
          Default is today.

-enddate <string>

          Set the end date of the appointment in format "%Y-%m-%d %H:%M:%S".
          Default is today.

-category <string>

          Assign category to appointment. If specified category does not
          yet exist, it is created.
          Default: No category.

-location <string>

          Set the location of the appointment.
          Default: No location.

-body <string>

          Set the body text of the appointment.
          Default: No body text.

-alldayevent true|false

          Specify, if appointment is an all day event.
          Default: false

-reminder true|false

          Specify, if appointment has a reminder set.
          Default: true

-busystate <OlBusyStatus>

          Set the busy status of the appointment.
          Possible values: olBusy olFree olOutOfOffice olTentative olWorkingElsewhere
          Default: olBusy

-importance <OlImportance>

          Set the importance of the appointment.
          Possible values: olImportanceHigh olImportanceLow olImportanceNormal
          Default: olImportanceNormal

-sensitivity <OlSensitivity>

          Set the sensitivity of the appointment.
          Possible values: olConfidential olNormal olPersonal olPrivate
          Default: olNormal

-isrecurring

          Get the recurring flag of the appointment.
          Only available for procedure GetAppointmentProperties.

See also: CreateMail AddHolidayAppointment GetAppointmentProperties GetNumAppointments

#### AddCalendar [::Outlook]

Outlook, Top

Add a new calendar.

AddCalendar appId calendarName

###### Parameters

appId | Identifier of the Outlook instance.
calendarName | Name of the new calendar.

###### Return value

Returns the identifier of the new calendar.

###### Description

Add a new calendar.

If a calendar with given name is already existing, the identifier of that calendar is returned. If the calendar could not be added an error is thrown.

See also: GetNumCalendars HaveCalendar GetCalendarNames GetCalendarId DeleteCalendar

#### AddCategory [::Outlook]

Outlook, Top

Add a new category to the Outlook categories.

AddCategory appId name color

###### Parameters

appId | Identifier of the Outlook instance.
name | Name of the new category.
color | (optional, default ) Value of enumeration type OlCategoryColor (see outlookConst.tcl) or category color name. If set to the empty string, a color is choosen automatically by Outlook.

###### Return value

Returns the identifier of the new category.

###### Description

Add a new category to the Outlook categories.

If a category with given name is already existing, the identifier of that category is returned.

See also: HaveCategory GetNumCategories GetCategoryNames GetCategoryId DeleteCategory GetCategoryColor

#### AddHolidayAppointment [::Outlook]

Outlook, Top

Create a new appointment in an Outlook calendar.

AddHolidayAppointment calId subject args

###### Parameters

calId | Identifier of the Outlook calendar.
subject | Subject text.
args | List of key value pairs specifying appointment configure options and its values.

###### Return value

Returns the identifier of the new appointment object.

###### Description

Create a new appointment in an Outlook calendar.

Option keys:

-date

          Set the date of the appointment in format "%Y-%m-%d".
          Default is today.

-category

          Assign category to appointment. Value is of type string.
          Default: No category.

-location

          Set the location of the appointment. Value is of type string.
          Default: No location.

The appointment has the following properties automatically set:

      All-Day event, No reminder, OutOfOffice status.

See also: CreateMail AddAppointment ApplyHolidayFile GetNumAppointments

#### ApplyHolidayFile [::Outlook]

Outlook, Top

Read an Outlook holiday file and insert appointments.

ApplyHolidayFile calId fileName category

###### Parameters

calId | Identifier of the Outlook calendar.
fileName | Name of the Outlook holiday file.
category | (optional, default ) Assign category to appointment. Default: No category.

###### Return value

Returns no value. If the holiday file could not be read, an error is thrown.

###### Description

Read an Outlook holiday file and insert appointments.

See also: ReadHolidayFile AddHolidayAppointment

#### CreateHtmlMail [::Outlook]

Outlook, Top

Create a new Outlook HTML mail.

CreateHtmlMail appId recipientList subject body attachmentList

###### Parameters

appId | Identifier of the Outlook instance.
recipientList | List of mail addresses.
subject | (optional, default ) Subject text.
body | (optional, default ) Mail body text in HTML format.
attachmentList | (optional, default ) List of files used as attachment.

###### Return value

Returns the identifier of the new mail object.

###### Description

Create a new Outlook HTML mail.

See also: CreateMail SendMail

#### CreateMail [::Outlook]

Outlook, Top

Create a new Outlook text mail.

CreateMail appId recipientList subject body attachmentList

###### Parameters

appId | Identifier of the Outlook instance.
recipientList | List of mail addresses.
subject | (optional, default ) Subject text.
body | (optional, default ) Mail body text.
attachmentList | (optional, default ) List of files used as attachment.

###### Return value

Returns the identifier of the new mail object.

###### Description

Create a new Outlook text mail.

See also: CreateHtmlMail SendMail

#### DeleteAppointmentByIndex [::Outlook]

Outlook, Top

Delete an appointment of an Outlook calendar by its index.

DeleteAppointmentByIndex calId index

###### Parameters

calId | Identifier of the Outlook calendar.
index | Index of the appointment.

###### Return value

Returns no value.

###### Description

Delete an appointment of an Outlook calendar by its index.

The first appointment has index 1. Instead of using the numeric index the special word "end" may be used to specify the last appointment. If the index is out of bounds an error is thrown.

See also: GetNumAppointments GetAppointmentByIndex AddAppointment

#### DeleteCalendar [::Outlook]

Outlook, Top

Delete an Outlook calendar.

DeleteCalendar calId

###### Parameters

calId | Identifier of the Outlook calendar.

###### Return value

Returns no value.

###### Description

Delete an Outlook calendar.

See also: GetNumCalendars HaveCalendar GetCalendarNames GetCalendarId AddCalendar

#### DeleteCategory [::Outlook]

Outlook, Top

Delete an Outlook category.

DeleteCategory appId indexOrName

###### Parameters

appId |
indexOrName | Index or name of the Outlook category.

###### Return value

Returns no value.

###### Description

Delete an Outlook category.

See also: AddCategory HaveCategory GetNumCategories GetCategoryNames GetCategoryId DeleteCategory

#### GetAppointmentByIndex [::Outlook]

Outlook, Top

Get an appointment of an Outlook calendar by its index.

GetAppointmentByIndex calId index

###### Parameters

calId | Identifier of the Outlook calendar.
index | Index of the appointment.

###### Return value

Returns the identifier of the found appointment.

###### Description

Get an appointment of an Outlook calendar by its index.

The first appointment has index 1. Instead of using the numeric index the special word "end" may be used to specify the last appointment. If the index is out of bounds an error is thrown.

See also: GetNumAppointments DeleteAppointmentByIndex AddAppointment

#### GetAppointmentProperties [::Outlook]

Outlook, Top

Get properties of an appointment.

GetAppointmentProperties appointId args

###### Parameters

appointId | Identifier of the Outlook appointment.
args | List of keys specifying appointment configure options.

###### Return value

Returns the appointment properties as a list of values. The list elements have the same order as the list of keys.

###### Description

Get properties of an appointment.

Option keys:

See AddAppointment for a list of configure options.

See also: AddAppointment GetNumAppointments

#### GetCalendarId [::Outlook]

Outlook, Top

Get a calendar by its name.

GetCalendarId appId calendarName

###### Parameters

appId | Identifier of the Outlook instance.
calendarName | (optional, default ) Name of the calendar to find.

###### Return value

Returns the identifier of the found calendar.

###### Description

Get a calendar by its name.

If a calendar with given name does not exist an error is thrown.

See also: GetNumCalendars HaveCalendar GetCalendarNames AddCalendar DeleteCalendar

#### GetCalendarNames [::Outlook]

Outlook, Top

Get a list of calendar names.

GetCalendarNames appId

###### Parameters

appId | Identifier of the Outlook instance.

###### Return value

Returns a list of calendar names.

###### Description

Get a list of calendar names.

See also: GetNumCalendars HaveCalendar GetCalendarId AddCalendar DeleteCalendar

#### GetCategoryColor [::Outlook]

Outlook, Top

Convert a category color enumeration or name into a hexadecimal Tcl color string representation.

GetCategoryColor colorEnumOrName

###### Parameters

colorEnumOrName | A category color enumeration or name.

###### Return value

Returns the hexadecimal representation of the specified color, ex. "#00FFAA".

###### Description

Convert a category color enumeration or name into a hexadecimal Tcl color string representation.

Outlook category colors can be specified in one of the following representations:

      Enum: A value of enumeration OlCategoryColor (see outlookConst.tcl).
      Name: Enumeration name without prefix "olCategoryColor".
            Example: Name of Outlook::olCategoryColorBlack is "Black".

See also: ::Cawt::GetColor GetCategoryColorEnum GetCategoryColorName GetCategoryColorNames

#### GetCategoryColorEnum [::Outlook]

Outlook, Top

Convert a category color enumeration or name into a color enumeration.

GetCategoryColorEnum colorEnumOrName

###### Parameters

colorEnumOrName | A category color enumeration or name.

###### Return value

Returns the category color enumeration.

###### Description

Convert a category color enumeration or name into a color enumeration.

See GetCategoryColor for a description of color enumerations and names.

See also: ::Cawt::GetColor GetCategoryColor GetCategoryColorName GetCategoryColorNames

#### GetCategoryColorName [::Outlook]

Outlook, Top

Convert a category color enumeration into a category color name.

GetCategoryColorName colorEnum

###### Parameters

colorEnum | A category color enumeration.

###### Return value

Returns the category color name.

###### Description

Convert a category color enumeration into a category color name.

See GetCategoryColor for a description of color enumerations and names.

See also: ::Cawt::GetColor GetCategoryColor GetCategoryColorEnum GetCategoryColorNames

#### GetCategoryColorNames [::Outlook]

Outlook, Top

Get all category color names.

GetCategoryColorNames

###### Return value

Returns a list of all category color names.

###### Description

Get all category color names.

See GetCategoryColor for a description of color enumerations and names.

See also: ::Cawt::GetColor GetCategoryColor GetCategoryColorEnum GetCategoryColorName

#### GetCategoryId [::Outlook]

Outlook, Top

Get a category by its index or name.

GetCategoryId appId indexOrName

###### Parameters

appId | Identifier of the Outlook instance.
indexOrName | Index or name of the category.

###### Return value

Returns the identifier of the found category.

###### Description

Get a category by its index or name.

The first category has index 1. If the index is out of bounds or the category name does not exist, an error is thrown.

See also: HaveCategory GetNumCategories GetCategoryNames AddCategory DeleteCategory

#### GetCategoryNames [::Outlook]

Outlook, Top

Get a list of category names.

GetCategoryNames appId

###### Parameters

appId | Identifier of the Outlook instance.

###### Return value

Returns a list of category names.

###### Description

Get a list of category names.

See also: HaveCategory GetNumCategories GetCategoryId AddCategory DeleteCategory

#### GetEnum [::Outlook]

Outlook, Top

Get numeric value of an enumeration.

GetEnum enumOrString

###### Parameters

enumOrString | Enumeration name

###### Return value

Returns the numeric value of an enumeration.

###### Description

Get numeric value of an enumeration.

See also: GetEnumName GetEnumTypes GetEnumVal GetEnumNames

#### GetEnumName [::Outlook]

Outlook, Top

Get name of a given enumeration type and numeric value.

GetEnumName enumType enumVal

###### Parameters

enumType | Enumeration type
enumVal | Enumeration numeric value.

###### Return value

Returns a list of names of a given enumeration type.

###### Description

Get name of a given enumeration type and numeric value.

See also: GetEnumNames GetEnumTypes GetEnumVal GetEnum

#### GetEnumNames [::Outlook]

Outlook, Top

Get names of a given enumeration type.

GetEnumNames enumType

###### Parameters

enumType | Enumeration type

###### Return value

Returns a list of names of a given enumeration type.

###### Description

Get names of a given enumeration type.

See also: GetEnumName GetEnumTypes GetEnumVal GetEnum

#### GetEnumTypes [::Outlook]

Outlook, Top

Get available enumeration types.

GetEnumTypes

###### Return value

Returns a list of available enumeration types.

###### Description

Get available enumeration types.

See also: GetEnumName GetEnumNames GetEnumVal GetEnum

#### GetEnumVal [::Outlook]

Outlook, Top

Get numeric value of an enumeration name.

GetEnumVal enumName

###### Parameters

enumName | Enumeration name

###### Return value

Returns the numeric value of an enumeration name.

###### Description

Get numeric value of an enumeration name.

See also: GetEnumName GetEnumTypes GetEnumNames GetEnum

#### GetFoldersRecursive [::Outlook]

Outlook, Top

GetFoldersRecursive appId type

###### Parameters

appId |
type |

#### GetMailIds [::Outlook]

Outlook, Top

Get a list of mail identifiers.

GetMailIds appId

###### Parameters

appId | Identifier of the Outlook instance.

###### Return value

Returns a list of mail identifiers.

###### Description

Get a list of mail identifiers.

See also: GetMailSubjects CreateMail SendMail

#### GetMailSubjects [::Outlook]

Outlook, Top

Get a list of mail subjects.

GetMailSubjects appId

###### Parameters

appId | Identifier of the Outlook instance.

###### Return value

Returns a list of mail subjects.

###### Description

Get a list of mail subjects.

See also: GetMailIds CreateMail SendMail

#### GetNumAppointments [::Outlook]

Outlook, Top

Get the number of appointments in an Outlook calendar.

GetNumAppointments calId

###### Parameters

calId | Identifier of the Outlook calendar.

###### Return value

Returns the number of Outlook appointments.

###### Description

Get the number of appointments in an Outlook calendar.

See also: GetAppointmentByIndex DeleteAppointmentByIndex AddAppointment

#### GetNumCalendars [::Outlook]

Outlook, Top

Get the number of Outlook calendars.

GetNumCalendars appId

###### Parameters

appId | Identifier of the Outlook instance.

###### Return value

Returns the number of Outlook calendars.

###### Description

Get the number of Outlook calendars.

See also: HaveCalendar GetCalendarNames GetCalendarId AddCalendar DeleteCalendar

#### GetNumCategories [::Outlook]

Outlook, Top

Get the number of Outlook categories.

GetNumCategories appId

###### Parameters

appId | Identifier of the Outlook instance.

###### Return value

Returns the number of Outlook categories.

###### Description

Get the number of Outlook categories.

See also: HaveCategory GetCategoryNames GetCategoryId AddCategory DeleteCategory

#### GetVersion [::Outlook]

Outlook, Top

Get the version of an Outlook application.

GetVersion objId useString

###### Parameters

objId | Identifier of an Outlook object instance.
useString | (optional, default false) true: Return the version name (ex. "Outlook 2000"). false: Return the version number (ex. "9.0").

###### Return value

Returns the version of an Outlook application.

###### Description

Get the version of an Outlook application.

Both version name and version number are returned as strings. Version number is in a format, so that it can be evaluated as a floating point number.

See also: Open

#### HaveCalendar [::Outlook]

Outlook, Top

Check, if a calendar already exists.

HaveCalendar appId calendarName

###### Parameters

appId | Identifier of the Outlook instance.
calendarName | Name of the calendar to check.

###### Return value

Returns true, if the calendar exists, otherwise false.

###### Description

Check, if a calendar already exists.

See also: GetNumCalendars GetCalendarNames GetCalendarId AddCalendar DeleteCalendar

#### HaveCategory [::Outlook]

Outlook, Top

Check, if a category already exists.

HaveCategory appId categoryName

###### Parameters

appId | Identifier of the Outlook instance.
categoryName | Name of the category to check.

###### Return value

Returns true, if the category exists, otherwise false.

###### Description

Check, if a category already exists.

See also: HaveCategory GetCategoryNames GetCategoryId AddCategory DeleteCategory GetCategoryColor

#### Open [::Outlook]

Outlook, Top

Open an Outlook instance.

Open explorerType

###### Parameters

explorerType | (optional, default olFolderInbox) Value of enumeration type OlDefaultFolders (see outlookConst.tcl). Typical values are: olFolderCalendar, olFolderInbox, olFolderTasks.

###### Return value

Returns the identifier of the Outlook application instance.

###### Description

Open an Outlook instance.

See also: OpenNew Quit

#### OpenNew [::Outlook]

Outlook, Top

Obsolete: Replaced with Open in version 2.4.1

OpenNew explorerType

###### Parameters

explorerType | (optional, default olFolderInbox)

###### Description

Obsolete: Replaced with Open in version 2.4.1

#### Quit [::Outlook]

Outlook, Top

Quit an Outlook instance.

Quit appId

###### Parameters

appId | Identifier of the Outlook instance.

###### Return value

Returns no value.

###### Description

Quit an Outlook instance.

See also: Open

#### ReadHolidayFile [::Outlook]

Outlook, Top

Read an Outlook holiday file.

ReadHolidayFile fileName

###### Parameters

fileName | Name of the Outlook holiday file.

###### Return value

Returns the data of the holiday file as a dict with the following keys: "SectionList" : The list of sections in the holiday file.

###### Description

Read an Outlook holiday file.

      For each section the following keys are set:
      "SubjectList_$section": The list of subjects of this section.
      "DateList_$section"   : The list of dates of this section.

If the holiday file could not be read, an error is thrown.

See also: AddHolidayAppointment ApplyHolidayFile

#### SendMail [::Outlook]

Outlook, Top

Send an Outlook mail.

SendMail mailId

###### Parameters

mailId | Identifier of the Outlook mail object.

###### Return value

Returns no value.

###### Description

Send an Outlook mail.

See also: CreateMail CreateHtmlMail

# ::Ppt

## Introduction

The Ppt namespace provides commands to control Microsoft PowerPoint.

## Commands

#### AddPres [::Ppt]

Ppt, Top

Add a new empty presentation.

AddPres appId templateFile

###### Parameters

appId | Identifier of the PowerPoint instance.
templateFile | (optional, default ) Name of an optional template file.

###### Return value

Returns the identifier of the new presentation.

###### Description

Add a new empty presentation.

See also: OpenPres GetActivePres

#### AddShape [::Ppt]

Ppt, Top

Add a new shape to a slide.

AddShape slideId shapeType left top width height args

###### Parameters

slideId | Identifier of the slide.
shapeType | Value of enumeration type MsoAutoShapeType (see officeConst.tcl). Typical values: msoShapeRectangle, msoShapeBalloon, msoShapeOval.
left | Left corner of the shape.
top | Top corner of the shape.
width | Width of the shape.
height | Height of the shape.
args | List of key value pairs specifying shape configure options and its values.

###### Return value

Returns the identifier of the new shape.

###### Description

Add a new shape to a slide.

The position and size values are specified in a format acceptable by procedure ::Cawt::ValueToPoints, i.e. centimeters, inches or points.

For a description of the configure options see ConfigureShape.

See also: ConnectShapes ConfigureShape GetNumSites

#### AddSlide [::Ppt]

Ppt, Top

Add a new slide to a presentation.

AddSlide presId type slideIndex

###### Parameters

presId | Identifier of the presentation.
type | (optional, default ppLayoutBlank) Value of enumeration type PpSlideLayout (see pptConst.tcl) or CustomLayout object.
slideIndex | (optional, default -1) Insertion index of new slide. Slide indices start at 1. If negative or "end", add slide at the end.

###### Return value

Returns the identifier of the new slide.

###### Description

Add a new slide to a presentation.

Note, that CustomLayouts are not supported with PowerPoint versions before 2007.

See also: CopySlide GetNumSlides GetCustomLayoutName GetCustomLayoutId

#### AddTextbox [::Ppt]

Ppt, Top

Add a text box into a slide.

AddTextbox slideId left top width height

###### Parameters

slideId | Identifier of the slide where the text box is inserted.
left | X position of top-left text box position.
top | Y position of top-left text box position.
width | Width of text box.
height | Height of text box.

###### Return value

Returns the identifier of the new text box.

###### Description

Add a text box into a slide.

The position and size values may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: AddTextboxText SetTextboxFontSize ::Cawt::ValueToPoints

#### AddTextboxText [::Ppt]

Ppt, Top

Add a text string to a text box.

AddTextboxText textboxId text addNewline

###### Parameters

textboxId | Identifier of the text box where the text is inserted.
text | The text to be inserted.
addNewline | (optional, default false) Add a new line after the text.

###### Return value

Returns no value.

###### Description

Add a text string to a text box.

See also: AddTextbox SetTextboxFontSize

#### Close [::Ppt]

Ppt, Top

Close a presentation without saving changes.

Close presId

###### Parameters

presId | Identifier of the presentation to close.

###### Return value

Returns no value.

###### Description

Close a presentation without saving changes.

Use the SaveAs method before closing, if you want to save changes.

See also: SaveAs CloseAll

#### CloseAll [::Ppt]

Ppt, Top

Close all presentations of a PowerPoint instance.

CloseAll appId

###### Parameters

appId | Identifier of the PowerPoint instance.

###### Return value

Returns no value.

###### Description

Close all presentations of a PowerPoint instance.

Use the SaveAs method before closing, if you want to save changes.

See also: SaveAs Close

#### ConfigureConnector [::Ppt]

Ppt, Top

Configure a connector.

ConfigureConnector connId args

###### Parameters

connId | Identifier of the connector.
args | List of key value pairs specifying the connector configure options and its values.

###### Return value

Returns no value.

###### Description

Configure a connector.

Option keys:

-beginarrow

          Set the type of the begin arrow.
          Value is of enumeration type MsoArrowheadStyle (see officeConst.tcl).
          Typical values: msoArrowheadTriangle, msoArrowheadNone, msoArrowheadDiamond.

-endarrow

          Set the type of the end arrow.
          Value is of enumeration type MsoArrowheadStyle (see officeConst.tcl).
          Typical values: msoArrowheadTriangle, msoArrowheadNone, msoArrowheadDiamond.

-beginsite

          Set the begin site of the connector.
          Value is an integer. 1 is the top site and continues counter clockwise.

-endsite

          Set the end site of the connector.
          Value is an integer. 1 is the top site and continues counter clockwise.

-weight

          Set the weight (thickness) of the connector line.
          Value can be specified in a format acceptable by
          procedure ::Cawt::ValueToPoints, i.e. centimeters, inches or points.

-fillcolor

          Set the fill color of the connector.
          Value may be specified in a format acceptable by procedure ::Cawt::GetColor,
          i.e. color name, hexadecimal string, Office color number or a list of 3 integer RGB values.

-type

          Set the type of the connector.
          Value is of enumeration type MsoConnectorType (see officeConst.tcl).
          Typical values: msoConnectorStraight, msoConnectorElbow, msoConnectorCurve.

See also: ConnectShapes GetNumSites ::Cawt::GetColor ::Cawt::ValueToPoints

#### ConfigureShape [::Ppt]

Ppt, Top

Configure a shape.

ConfigureShape shapeId args

###### Parameters

shapeId | Identifier of the shape.
args | List of key value pairs specifying the shape configure options and its values.

###### Return value

Returns no value.

###### Description

Configure a shape.

Option keys:

-fillcolor

          Set the fill color of the shape.
          Value may be specified in a format acceptable by procedure ::Cawt::GetColor,
          i.e. color name, hexadecimal string, Office color number or a list of 3 integer RGB values.

-text

          Set the text displayed inside the shape. Value is of type string.

-textsize

          Set the font size of the shape text. Value is specified in a format acceptable by
          procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

-textcolor

          Set the text color of the shape.
          Value may be specified in a format acceptable by procedure ::Cawt::GetColor,
          i.e. color name, hexadecimal string, Office color number or a list of 3 integer RGB values.

-valign

          Value is of enumeration type MsoVerticalAnchor (see officeConst.tcl).
          Typical values: msoAnchorTop, msoAnchorMiddle, msoAnchorBottom.

See also: AddShape GetNumSites ::Cawt::ValueToPoints ::Cawt::GetColor

#### ConnectShapes [::Ppt]

Ppt, Top

Add a new connector connecting two shapes.

ConnectShapes slideId fromShapeId toShapeId args

###### Parameters

slideId | Identifier of the slide.
fromShapeId | Identifier of the source shape.
toShapeId | Identifier of the target shape.
args | List of key value pairs specifying connector configure options and its values.

###### Return value

Returns the identifier of the new connector.

###### Description

Add a new connector connecting two shapes.

For a description of the configure options see ConfigureConnector.

- Default is a straight line connector (msoConnectorStraight) with an end arrow of type msoArrowheadTriangle.
- The connector is automatically placed by Office using RerouteConnections.

See also: AddShape ConfigureConnector

#### CopySlide [::Ppt]

Ppt, Top

Make a copy of a slide.

CopySlide presId fromSlideIndex toSlideIndex toPresId

###### Parameters

presId | Identifier of the presentation.
fromSlideIndex | Index of source slide. Slide indices start at 1. If negative or "end", use last slide as source.
toSlideIndex | (optional, default -1) Insertion index of copied slide. Slide indices start at 1. If negative or "end", insert slide at the end.
toPresId | (optional, default ) Identifier of the presentation the slide is copied to. If not specified or the empty string, the slide is copied into presentation presId.

###### Return value

Returns the identifier of the new slide.

###### Description

Make a copy of a slide.

A new empty slide is created at the insertion index and the contents of the source slide are copied into the new slide.

See also: AddSlide GetNumSlides

#### ExitSlideShow [::Ppt]

Ppt, Top

Exit specified slide show.

ExitSlideShow slideShowId

###### Parameters

slideShowId | Identifier of the slide show as returned by UseSlideShow.

###### Return value

Returns no value.

###### Description

Exit specified slide show.

See also: GetNumSlideShows UseSlideShow SlideShowNext

#### ExportPptFile [::Ppt]

Ppt, Top

Export a PowerPoint file to an image sequence.

ExportPptFile pptFile outputDir outputFileFmt startIndex endIndex imgType width height useMaster genHtmlTable thumbsPerRow thumbSize

###### Parameters

pptFile | Name of the PowerPoint file.
outputDir | Name of the output folder.
outputFileFmt | Name of the output file names.
startIndex | (optional, default 1) Start index for slide export.
endIndex | (optional, default end) End index for slide export.
imgType | (optional, default GIF) Name of the image format filter. This is the name as stored in the Windows registry. Ex: "GIF", "PNG".
width | (optional, default -1) Width of the generated images in pixels.
height | (optional, default -1) Height of the generated images in pixels.
useMaster | (optional, default true) true: Export with the contents of the master slide. false: Do not export the contents of the master slide.
genHtmlTable | (optional, default true) Additionally generate a HTML table with preview images.
thumbsPerRow | (optional, default 4) Number of preview images per HTML table row.
thumbSize | (optional, default 150) Maximum size of the preview images in pixels.

###### Return value

Returns no value.

###### Description

Export a PowerPoint file to an image sequence.

If the output directory does not exist, it is created. Caution: All existing files in the output directory are deleted before exporting.

The output file name must contain either a "%s" or a "%d" format. In the first case, it is assumed that each slide has a comment of the form "Export: Name", where "Name" is substituted for the "%s" format option. If the output file name contains a "%d" format option, the slide number is substituted instead.

If width and height are not specified or less than zero, the default sizes of PowerPoint are used.

See also: ExportSlide ExportSlides

#### ExportSlide [::Ppt]

Ppt, Top

Export a slide as an image.

ExportSlide slideId outputFile imgType width height

###### Parameters

slideId | Identifier of the slide.
outputFile | Name of the output file.
imgType | (optional, default GIF) Name of the image format filter. This is the name as stored in the Windows registry. Ex: "GIF", "PNG".
width | (optional, default -1) Width of the generated images in pixels.
height | (optional, default -1) Height of the generated images in pixels.

###### Return value

Returns no value. If the export failed, an error is thrown.

###### Description

Export a slide as an image.

If width and height are not specified or less than zero, the default sizes of PowerPoint are used.

See also: ExportPptFile ExportSlides

#### ExportSlides [::Ppt]

Ppt, Top

Export a range of slides as image files.

ExportSlides presId outputDir outputFileFmt startIndex endIndex imgType width height

###### Parameters

presId | Identifier of the presentation.
outputDir | Name of the output folder.
outputFileFmt | Name of the output file names.
startIndex | (optional, default 1) Start index for slide export.
endIndex | (optional, default end) End index for slide export.
imgType | (optional, default GIF) Name of the image format filter. This is the name as stored in the Windows registry. Ex: "GIF", "PNG".
width | (optional, default -1) Width of the generated images in pixels.
height | (optional, default -1) Height of the generated images in pixels.

###### Return value

Returns no value. If the export failed, an error is thrown.

###### Description

Export a range of slides as image files.

If the output directory does not exist, it is created.

The output file name must contain either a "%s" or a "%d" format. In the first case, it is assumed that each slide has a comment of the form "Export: Name", where "Name" is substituted for the "%s" format option. If the output file name contains a "%d" format option, the slide number is substituted instead.

If width and height are not specified or less than zero, the default sizes of PowerPoint are used.

See also: ExportPptFile ExportSlide

#### GetActivePres [::Ppt]

Ppt, Top

Return the active presentation of an application.

GetActivePres appId

###### Parameters

appId | Identifier of the PowerPoint instance.

###### Return value

Returns the identifier of the active presentation.

###### Description

Return the active presentation of an application.

See also: OpenPres AddPres

#### GetCommentKeyTopPosition [::Ppt]

Ppt, Top

Return the top position of a comment with specific key.

GetCommentKeyTopPosition slideId key

###### Parameters

slideId | Identifier of the slide.
key | Key to search for.

###### Return value

Returns the top position of the comment, if the key is found in the comments. Otherwise an empty string is returned.

###### Description

Return the top position of a comment with specific key.

All comments of the specified slide are searched for strings of the form "Key: Value".

See also: GetNumComments GetComments GetCommentKeyValue ExportSlides

#### GetCommentKeyValue [::Ppt]

Ppt, Top

Return the value of a key stored in a comment.

GetCommentKeyValue slideId key

###### Parameters

slideId | Identifier of the slide.
key | Key to search for.

###### Return value

Returns the corresponding value, if the key is found in the comments. Otherwise an empty string is returned.

###### Description

Return the value of a key stored in a comment.

All comments of the specified slide are search for strings of the form "Key: Value".

See also: GetNumComments GetComments GetCommentKeyTopPosition ExportSlides

#### GetComments [::Ppt]

Ppt, Top

Get the comment texts of a slide as a Tcl list.

GetComments slideId

###### Parameters

slideId | Identifier of the slide.

###### Description

Get the comment texts of a slide as a Tcl list.

See also: GetNumComments GetCommentKeyValue

#### GetCustomLayoutId [::Ppt]

Ppt, Top

Get a custom layout by its index or name.

GetCustomLayoutId presId indexOrName

###### Parameters

presId | Identifier of the presentation containing the custom layout.
indexOrName | Index or name of the custom layout to find.

###### Return value

Returns the identifier of the found custom layout. If the index is out of bounds or a custom layout with specified name is not found, an error is thrown.

###### Description

Get a custom layout by its index or name.

Instead of using the numeric index the special word "end" may be used to specify the last custom layout.

See also: GetNumCustomLayouts GetCustomLayoutName AddPres

#### GetCustomLayoutName [::Ppt]

Ppt, Top

Return the name of a custom layout.

GetCustomLayoutName customLayoutId

###### Parameters

customLayoutId | Identifier of the custom layout.

###### Return value

Returns the name of a custom layout.

###### Description

Return the name of a custom layout.

See also: GetCustomLayoutId GetNumCustomLayouts

#### GetEnum [::Ppt]

Ppt, Top

Get numeric value of an enumeration.

GetEnum enumOrString

###### Parameters

enumOrString | Enumeration name

###### Return value

Returns the numeric value of an enumeration.

###### Description

Get numeric value of an enumeration.

See also: GetEnumName GetEnumTypes GetEnumVal GetEnumNames

#### GetEnumName [::Ppt]

Ppt, Top

Get name of a given enumeration type and numeric value.

GetEnumName enumType enumVal

###### Parameters

enumType | Enumeration type
enumVal | Enumeration numeric value.

###### Return value

Returns a list of names of a given enumeration type.

###### Description

Get name of a given enumeration type and numeric value.

See also: GetEnumNames GetEnumTypes GetEnumVal GetEnum

#### GetEnumNames [::Ppt]

Ppt, Top

Get names of a given enumeration type.

GetEnumNames enumType

###### Parameters

enumType | Enumeration type

###### Return value

Returns a list of names of a given enumeration type.

###### Description

Get names of a given enumeration type.

See also: GetEnumName GetEnumTypes GetEnumVal GetEnum

#### GetEnumTypes [::Ppt]

Ppt, Top

Get available enumeration types.

GetEnumTypes

###### Return value

Returns a list of available enumeration types.

###### Description

Get available enumeration types.

See also: GetEnumName GetEnumNames GetEnumVal GetEnum

#### GetEnumVal [::Ppt]

Ppt, Top

Get numeric value of an enumeration name.

GetEnumVal enumName

###### Parameters

enumName | Enumeration name

###### Return value

Returns the numeric value of an enumeration name.

###### Description

Get numeric value of an enumeration name.

See also: GetEnumName GetEnumTypes GetEnumNames GetEnum

#### GetExtString [::Ppt]

Ppt, Top

Return the default extension of a PowerPoint file.

GetExtString appId

###### Parameters

appId | Identifier of the PowerPoint instance.

###### Return value

Returns the default extension of a PowerPoint file.

###### Description

Return the default extension of a PowerPoint file.

Starting with PowerPoint 12 (2007) this is the string ".pptx". In previous versions it was ".ppt".

See also: ::Office::GetOfficeType

#### GetNumComments [::Ppt]

Ppt, Top

Return the number of comments of a slide.

GetNumComments slideId

###### Parameters

slideId | Identifier of the slide.

###### Return value

Returns the number of comments of a slide.

###### Description

Return the number of comments of a slide.

See also: GetComments GetCommentKeyValue

#### GetNumCustomLayouts [::Ppt]

Ppt, Top

Return the number of custom layouts of a presentation.

GetNumCustomLayouts presId

###### Parameters

presId | Identifier of the presentation.

###### Return value

Returns the number of custom layouts of a presentation.

###### Description

Return the number of custom layouts of a presentation.

See also: GetNumSlides GetCustomLayoutName GetCustomLayoutId

#### GetNumShapes [::Ppt]

Ppt, Top

Return the number of shapes of a slide.

GetNumShapes slideId

###### Parameters

slideId | Identifier of the slide.

###### Return value

Returns the number of shapes of a slide.

###### Description

Return the number of shapes of a slide.

See also: AddShape GetShapeId ConfigureShape ConnectShapes

#### GetNumSites [::Ppt]

Ppt, Top

Return the number of sites of a shape.

GetNumSites shapeId

###### Parameters

shapeId | Identifier of the shape.

###### Return value

Returns the number of sites of a shape.

###### Description

Return the number of sites of a shape.

A site is the anchor point of a shape, where the connectors are attached.

See also: AddShape ConfigureShape ConnectShapes

#### GetNumSlides [::Ppt]

Ppt, Top

Return the number of slides of a presentation.

GetNumSlides presId

###### Parameters

presId | Identifier of the presentation.

###### Return value

Returns the number of slides of a presentation.

###### Description

Return the number of slides of a presentation.

See also: GetNumSlideShows

#### GetNumSlideShows [::Ppt]

Ppt, Top

Return the number of slide shows of a presentation.

GetNumSlideShows appId

###### Parameters

appId | Identifier of the PowerPoint instance.

###### Return value

Returns the number of slide shows of a presentation.

###### Description

Return the number of slide shows of a presentation.

See also: GetNumSlides UseSlideShow ExitSlideShow

#### GetPresImages [::Ppt]

Ppt, Top

Get the images of a presentation.

GetPresImages presId

###### Parameters

presId | Identifier of the presentation.

###### Return value

Returns a key value list containing the image name and its corresponding slide index.

###### Description

Get the images of a presentation.

See also: InsertImage GetPresVideos GetShapeType GetShapeMediaType

#### GetPresVideos [::Ppt]

Ppt, Top

Get the videos of a presentation.

GetPresVideos presId

###### Parameters

presId | Identifier of the presentation.

###### Return value

Returns a key value list containing the video name and its corresponding slide index.

###### Description

Get the videos of a presentation.

See also: InsertVideo GetPresImages GetShapeType GetShapeMediaType

#### GetShapeId [::Ppt]

Ppt, Top

Get shape identifier from shape index.

GetShapeId slideId shapeIndex

###### Parameters

slideId | Identifier of the slide.
shapeIndex | Index of the shape. Shape indices start at 1. If negative or "end", use last shape.

###### Return value

Returns the identifier of the shape.

###### Description

Get shape identifier from shape index.

See also: AddShape GetNumShapes GetShapeType

#### GetShapeMediaType [::Ppt]

Ppt, Top

Return the media type of a shape.

GetShapeMediaType shapeId useString

###### Parameters

shapeId | Identifier of the shape.
useString | (optional, default false) true : Return the enumeration as string. false: Return the enumeration as integer string.

###### Return value

Returns the media type of the shape as enumeration PpMediaType (see pptConst.tcl). Typical values: ppMediaTypeMovie ppMediaTypeSound

###### Description

Return the media type of a shape.

See also: AddShape GetShapeId GetNumShapes GetShapeType GetShapeName

#### GetShapeName [::Ppt]

Ppt, Top

Return the name of a shape.

GetShapeName shapeId

###### Parameters

shapeId | Identifier of the shape.

###### Return value

Returns the name of the shape as string.

###### Description

Return the name of a shape.

See also: SetShapeName AddShape GetShapeId GetNumShapes GetShapeType GetShapeMediaType

#### GetShapeType [::Ppt]

Ppt, Top

Return the type of a shape.

GetShapeType shapeId useString

###### Parameters

shapeId | Identifier of the shape.
useString | (optional, default false) true : Return the enumeration as string. false: Return the enumeration as integer string.

###### Return value

Returns the type of the shape as enumeration MsoShapeType (see officeConst.tcl). Typical values: msoMedia, msoTextBox, msoGraphic.

###### Description

Return the type of a shape.

See also: AddShape GetShapeId GetNumShapes GetShapeMediaType GetShapeName

#### GetSlideId [::Ppt]

Ppt, Top

Get slide identifier from slide index.

GetSlideId presId slideIndex

###### Parameters

presId | Identifier of the presentation.
slideIndex | Index of slide. Slide indices start at 1. If negative or "end", use last slide.

###### Return value

Returns the identifier of the slide.

###### Description

Get slide identifier from slide index.

See also: GetNumSlides AddSlide

#### GetSlideIndex [::Ppt]

Ppt, Top

Return the index of a slide.

GetSlideIndex slideId

###### Parameters

slideId | Identifier of the slide.

###### Return value

Returns the index of a slide.

###### Description

Return the index of a slide.

See also: GetNumSlides AddSlide

#### GetTemplateExtString [::Ppt]

Ppt, Top

Return the default extension of a PowerPoint template file.

GetTemplateExtString appId

###### Parameters

appId | Identifier of the PowerPoint instance.

###### Return value

Returns the default extension of a PowerPoint template file.

###### Description

Return the default extension of a PowerPoint template file.

Starting with PowerPoint 12 (2007) this is the string ".potx". In previous versions it was ".pot".

#### GetVersion [::Ppt]

Ppt, Top

Return the version of a PowerPoint application.

GetVersion objId useString

###### Parameters

objId | Identifier of a PowerPoint object instance.
useString | (optional, default false) true: Return the version name (ex. "PowerPoint 2003"). false: Return the version number (ex. "11.0").

###### Return value

Returns the version of a PowerPoint application. Both version name and version number are returned as strings. Version number is in a format, so that it can be evaluated as a floating point number.

###### Description

Return the version of a PowerPoint application.

See also: GetExtString

#### GetViewType [::Ppt]

Ppt, Top

Return the view type of a presentation.

GetViewType presId

###### Parameters

presId | Identifier of the presentation.

###### Return value

Returns the view type of a presentation.

###### Description

Return the view type of a presentation.

See also: SetViewType

#### InsertImage [::Ppt]

Ppt, Top

Insert an image into a slide.

InsertImage slideId imgFileName args

###### Parameters

slideId | Identifier of the slide where the image is inserted.
imgFileName | File name of the image.
args | List of key value pairs specifying video configure options and its values.

###### Return value

Returns the identifier of the inserted image.

###### Description

Insert an image into a slide.

Option keys:

-left <double>

          Set the X position of the top-left image position.

-top <double>

          Set the Y position of the top-left image position.

-width <double>

          Set the width of the image.

-height <double>

          Set the height of the image.

-link <bool>

          Indicates whether to link to the file.
          Default: false

-embed <bool>

          Indicates whether to save the image with the document.
          Default: true

The position and size values may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points. If no position or size values are specified, the image is placed automatically by PowerPoint.

See also: GetPresImages InsertVideo AddSlide ::Cawt::ValueToPoints

#### InsertVideo [::Ppt]

Ppt, Top

Insert a video into a slide.

InsertVideo slideId videoFileName args

###### Parameters

slideId | Identifier of the slide where the video is inserted.
videoFileName | File name of the video.
args | List of key value pairs specifying video configure options and its values.

###### Return value

Returns the identifier of the inserted video.

###### Description

Insert a video into a slide.

Option keys:

-left <double>

          Set the X position of top-left video position.

-top <double>

          Set the Y position of top-left video position.

-width <double>

          Set the width of the video.

-height <double>

          Set the height of the video.

-link <bool>

          Indicates whether to link to the file.
          Default: false

-embed <bool>

          Indicates whether to save the video with the document.
          Default: true

The position and size values may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points. If no position or size values are specified, the video is placed automatically by PowerPoint.

See also: GetPresVideos SetMediaPlaySettings InsertImage AddSlide ::Cawt::ValueToPoints

#### MoveSlide [::Ppt]

Ppt, Top

Move a slide to another position.

MoveSlide slideId slideIndex

###### Parameters

slideId | Identifier of the slide to be moved.
slideIndex | Index of new slide position. Slide indices start at 1. If negative or "end", move slide to the end of the presentation.

###### Description

Move a slide to another position.

#### Open [::Ppt]

Ppt, Top

Open a PowerPoint instance. Use an already running instance, if available.

Open width height

###### Parameters

width | (optional, default -1) Width of the application window. If negative, open with last used width.
height | (optional, default -1) Height of the application window. If negative, open with last used height.

###### Return value

Returns the identifier of the PowerPoint application instance.

###### Description

Open a PowerPoint instance. Use an already running instance, if available.

See also: OpenNew Quit

#### OpenNew [::Ppt]

Ppt, Top

Open a new PowerPoint instance.

OpenNew width height

###### Parameters

width | (optional, default -1) Width of the application window. If negative, open with last used width.
height | (optional, default -1) Height of the application window. If negative, open with last used height.

###### Return value

Returns the identifier of the new PowerPoint application instance.

###### Description

Open a new PowerPoint instance.

See also: Open Quit

#### OpenPres [::Ppt]

Ppt, Top

Open a presentation, i.e. load a PowerPoint file.

OpenPres appId fileName readOnly

###### Parameters

appId | Identifier of the PowerPoint instance.
fileName | Name of the PowerPoint file.
readOnly | (optional, default false) true: Open the presentation in read-only mode. false: Open the presentation in read-write mode.

###### Return value

Returns the identifier of the opened presentation. If the presentation was already open, activate that presentation and return the identifier to that presentation.

###### Description

Open a presentation, i.e. load a PowerPoint file.

See also: AddPres GetActivePres

#### Quit [::Ppt]

Ppt, Top

Quit a PowerPoint instance.

Quit appId showAlert

###### Parameters

appId | Identifier of the PowerPoint instance.
showAlert | (optional, default true) true: Show an alert window, if there are unsaved changes. false: Quit without saving any changes.

###### Return value

Returns no value.

###### Description

Quit a PowerPoint instance.

Note, that the showAlert parameter does not work. PowerPoint always quits without showing the alert window.

See also: Open

#### SaveAs [::Ppt]

Ppt, Top

Save a presentation to a PowerPoint file.

SaveAs presId fileName fmt embedFonts

###### Parameters

presId | Identifier of the presentation to save.
fileName | Name of the PowerPoint file.
fmt | (optional, default ) Value of enumeration type PpSaveAsFileType (see pptConst.tcl). If not given or the empty string, the file is stored in the native format corresponding to the used PowerPoint version (ppSaveAsDefault).
embedFonts | (optional, default true) true: Embed TrueType fonts. false: Do not embed TrueType fonts.

###### Return value

Returns no value.

###### Description

Save a presentation to a PowerPoint file.

Note: If "fmt" is not a PowerPoint format, but an image format, PowerPoint takes the specified file name and creates a directory with that name. Then it copies all slides as images into that directory. The slide images are automatically named by PowerPoint (ex. in German versions the slides are called Folie1.gif, Folie2.gif, ...). Use the ExportSlide procedure, if you want full control over image file names.

See also: ExportSlides ExportSlide

#### SetHyperlinkToSlide [::Ppt]

Ppt, Top

Create a hyperlink from a shape to a slide.

SetHyperlinkToSlide srcShapeId destSlideIdOrNum screenTip

###### Parameters

srcShapeId | Identifier of the source shape.
destSlideIdOrNum | Identifier or number of the destination slide.
screenTip | (optional, default ) Text to be displayed when hovering over the source shape.

###### Return value

Returns no value.

###### Description

Create a hyperlink from a shape to a slide.

See also: AddShape ConfigureShape

#### SetMediaPlaySettings [::Ppt]

Ppt, Top

Set the play settings of a media (audio or video).

SetMediaPlaySettings shapeId args

###### Parameters

shapeId | Identifier of the media shape.
args | List of key value pairs specifying the play configure options and its values.

###### Return value

Returns no value.

###### Description

Set the play settings of a media (audio or video).

Option keys:

-endless <bool>

        Determines whether the specified video or sound loops continuously
        until either the next video or sound starts, the user clicks the slide,
        or a slide transition occurs.
        Default: false

-hide <bool>

        Determines whether the specified media clip is hidden during a slide
        show except when it is playing.
        Default: false

-pause <bool>

        Determines whether the slide show pauses until the specified media clip
        is finished playing.
        Default: false

-play <bool>

        Determines whether the specified video or sound is played automatically
        when it is animated.
        Default: false

-rewind <bool>

        Determines whether the first frame of the specified video is automatically
        redisplayed as soon as the video has finished playing.
        Default: false

See also: InsertVideo GetPresVideos

#### SetPresPageSetup [::Ppt]

Ppt, Top

Set the page size of a presentation.

SetPresPageSetup presId args

###### Parameters

presId | Identifier of the presentation.
args | List of key value pairs specifying the page setup configure options and its values.

###### Return value

Returns no value.

###### Description

Set the page size of a presentation.

Option keys:

-width

          Set the width of the presentation slides.

-height

          Set the height of the presentation slides.

The width and height values may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: AddPres OpenPres ::Cawt::ValueToPoints

#### SetShapeName [::Ppt]

Ppt, Top

Set the name of a shape.

SetShapeName shapeId name

###### Parameters

shapeId | Identifier of the shape.
name | Name of the shape.

###### Return value

Returns no value.

###### Description

Set the name of a shape.

See also: GetShapeName AddShape GetShapeId GetNumShapes GetShapeType GetShapeMediaType

#### SetTextboxFontSize [::Ppt]

Ppt, Top

Set the font size of the text in a text box.

SetTextboxFontSize textboxId fontSize

###### Parameters

textboxId | Identifier of the text box where the text is inserted.
fontSize | Font size.

###### Return value

Returns no value.

###### Description

Set the font size of the text in a text box.

The size value may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: AddTextbox AddTextboxText

#### SetViewType [::Ppt]

Ppt, Top

Set the view type of a presentation.

SetViewType presId viewType

###### Parameters

presId | Identifier of the presentation.
viewType | Value of enumeration type PpViewType (see pptConst.tcl).

###### Return value

Returns no value.

###### Description

Set the view type of a presentation.

See also: GetViewType

#### ShowAlerts [::Ppt]

Ppt, Top

Toggle the display of PowerPoint application alerts.

ShowAlerts appId onOff

###### Parameters

appId | The application identifier.
onOff | Switch the alerts on or off.

###### Return value

Returns no value.

###### Description

Toggle the display of PowerPoint application alerts.

#### ShowSlide [::Ppt]

Ppt, Top

Show a specific slide.

ShowSlide presId slideIndex

###### Parameters

presId | Identifier of the presentation.
slideIndex | Index of slide. Slide indices start at 1. If negative or "end", show last slide.

###### Return value

Returns no value.

###### Description

Show a specific slide.

See also: GetNumSlides

#### SlideShowFirst [::Ppt]

Ppt, Top

Go to first slide in slide show.

SlideShowFirst slideShowId

###### Parameters

slideShowId | Identifier of the slide show.

###### Return value

Returns no value.

###### Description

Go to first slide in slide show.

See also: UseSlideShow SlideShowNext SlideShowPrev SlideShowLast

#### SlideShowLast [::Ppt]

Ppt, Top

Go to last slide in slide show.

SlideShowLast slideShowId

###### Parameters

slideShowId | Identifier of the slide show.

###### Return value

Returns no value.

###### Description

Go to last slide in slide show.

See also: UseSlideShow SlideShowNext SlideShowPrev SlideShowFirst

#### SlideShowNext [::Ppt]

Ppt, Top

Go to next slide in slide show.

SlideShowNext slideShowId

###### Parameters

slideShowId | Identifier of the slide show.

###### Return value

Returns no value.

###### Description

Go to next slide in slide show.

See also: UseSlideShow SlideShowPrev SlideShowFirst SlideShowLast

#### SlideShowPrev [::Ppt]

Ppt, Top

Go to previous slide in slide show.

SlideShowPrev slideShowId

###### Parameters

slideShowId | Identifier of the slide show.

###### Return value

Returns no value.

###### Description

Go to previous slide in slide show.

See also: UseSlideShow SlideShowNext SlideShowFirst SlideShowLast

#### UseSlideShow [::Ppt]

Ppt, Top

Use specified slide show.

UseSlideShow presId slideShowIndex

###### Parameters

presId | Identifier of the presentation.
slideShowIndex | Index of the slide show. Indices start at 1.

###### Return value

Returns the identifier of the specified slide show.

###### Description

Use specified slide show.

See also: GetNumSlides ExitSlideShow SlideShowNext

#### Visible [::Ppt]

Ppt, Top

Toggle the visibility of a PowerPoint application window.

Visible appId visible

###### Parameters

appId | Identifier of the PowerPoint instance.
visible | true: Show the application window. false: Hide the application window.

###### Return value

Returns no value.

###### Description

Toggle the visibility of a PowerPoint application window.

See also: Open OpenNew

# ::Reader

## Introduction

The Reader namespace provides commands to control Acrobat Reader.

## Commands

#### Open [::Reader]

Reader, Top

Open an Acrobat Reader instance. Use an already running instance, if available.

Open fileName args

###### Parameters

fileName | File name of PDF file to open.
args | List of key value pairs specifying the startup options and its values.

###### Return value

Returns no value.

###### Description

Open an Acrobat Reader instance. Use an already running instance, if available.

Option keys:

-nameddest

          Specify a named destination in the PDF document.

-page

          Specify a numbered page in the document, using an integer value.
          The document’s first page has a value of 1.

-zoom

          Specify a zoom factor in percent.

-pagemode

          Specify page display mode.
          Valid values: bookmarks thumbs none

-search

          Open the Search panel and perform a search for the
          words in the specified string. You can search only for single words.
          The first matching word is highlighted in the document.

-scrollbar

          Turn scrollbars on or off. Value is of type bool.

-toolbar

          Turn the toolbar on or off. Value is of type bool.

-statusbar

          Turn the status bar on or off. Value is of type bool.

-messages

          Turn document message bar on or off. Value is of type bool.

-navpanes

          Turn the navigation panes and tabs on or off. Value is of type bool.

Note, that above described options are only a subset of all available command line parameters. For a full list, see: http://www.adobe.com/content/dam/Adobe/en/devnet/acrobat/pdfs/pdf_open_parameters.pdf

See also: OpenNew Quit

#### OpenNew [::Reader]

Reader, Top

Open a new Acrobat Reader instance.

OpenNew fileName args

###### Parameters

fileName | File name of PDF file to open.
args | List of key value pairs specifying the startup options and its values.

###### Return value

Returns no value.

###### Description

Open a new Acrobat Reader instance.

For a detailled description of supported key value pairs see Open.

See also: Open Quit

#### Quit [::Reader]

Reader, Top

Quit all Acrobat Reader instances.

Quit

###### Return value

Returns no value.

###### Description

Quit all Acrobat Reader instances.

See also: Open OpenNew

#### SetReaderProg [::Reader]

Reader, Top

Set the path to Acrobat Reader program.

SetReaderProg fileName

###### Parameters

fileName | Full path name to Acrobat Reader program AcroRd32.exe

###### Return value

Returns no value.

###### Description

Set the path to Acrobat Reader program.

Use this precure, if the automatic detection of the path to Acrobat Reader does not work. Note, that this procedure must be called before calling Open or OpenNew.

See also: Open OpenNew

# ::Word

## Introduction

The Word namespace provides commands to control Microsoft Word.

## Commands

#### AddBookmark [::Word]

Word, Top

Add a bookmark to a text range.

AddBookmark rangeId name

###### Parameters

rangeId | Identifier of the text range.
name | Name of the bookmark.

###### Return value

Returns the bookmark identifier.

###### Description

Add a bookmark to a text range.

See also: SetLinkToBookmark GetBookmarkName

#### AddContentControl [::Word]

Word, Top

Add a content control to a text range.

AddContentControl rangeId type title

###### Parameters

rangeId | Identifier of the text range.
type | Value of enumeration type WdContentControlType (see wordConst.tcl). Often used values: wdContentControlCheckBox, wdContentControlText
title | (optional, default ) Title string for the control.

###### Return value

Returns the content control identifier.

###### Description

Add a content control to a text range.

See also: SetContentControlText SetContentControlDropdown

#### AddDocument [::Word]

Word, Top

Add a new empty document to a Word instance.

AddDocument appId type visible

###### Parameters

appId | Identifier of the Word instance.
type | (optional, default ) Value of enumeration type WdNewDocumentType (see wordConst.tcl).
visible | (optional, default true) true: Show the application window. false: Hide the application window.

###### Return value

Returns the identifier of the new document.

###### Description

Add a new empty document to a Word instance.

See also: OpenDocument

#### AddImageTable [::Word]

Word, Top

Add a new table and fill the cells with images.

AddImageTable rangeId numCols imgList captionList

###### Parameters

rangeId | Identifier of the text range.
numCols | Number of columns of the new table.
imgList | List of image file names.
captionList | (optional, default ) List of caption texts.

###### Return value

Returns the identifier of the new table.

###### Description

Add a new table and fill the cells with images.

See also: AddTable InsertImage

#### AddPageBreak [::Word]

Word, Top

Add a page break to a text range.

AddPageBreak rangeId

###### Parameters

rangeId | Identifier of the text range.

###### Return value

Returns no value.

###### Description

Add a page break to a text range.

See also: AddParagraph

#### AddParagraph [::Word]

Word, Top

Add a new paragraph to a document.

AddParagraph rangeId spaceAfter

###### Parameters

rangeId | Identifier of the text range.
spaceAfter | (optional, default -1) Spacing after the range.

###### Return value

Returns the new extended range.

###### Description

Add a new paragraph to a document.

The spacing value may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: AppendParagraph ::Cawt::ValueToPoints

#### AddRow [::Word]

Word, Top

Add one or more rows to a table.

AddRow tableId beforeRowNum numRows

###### Parameters

tableId | Identifier of the Word table.
beforeRowNum | (optional, default end) Insertion row number. Row numbering starts with 1. The new row is inserted before the given row number. If not specified or "end", the new row is appended at the end.
numRows | (optional, default 1) Number of rows to be inserted.

###### Return value

Returns no value.

###### Description

Add one or more rows to a table.

See also: DeleteRow GetNumRows

#### AddTable [::Word]

Word, Top

Add a new table in a text range.

AddTable rangeId numRows numCols spaceAfter

###### Parameters

rangeId | Identifier of the text range.
numRows | Number of rows of the new table.
numCols | Number of columns of the new table.
spaceAfter | (optional, default -1) Spacing in points after the table.

###### Return value

Returns the identifier of the new table.

###### Description

Add a new table in a text range.

The spacing value may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: DeleteTable GetNumTables GetNumRows GetNumColumns ::Cawt::ValueToPoints

#### AddText [::Word]

Word, Top

Add text to a Word document.

AddText rangeId text addParagraph style

###### Parameters

rangeId | Identifier of the text range.
text | Text string to be added.
addParagraph | (optional, default false) Add a paragraph after the text.
style | (optional, default wdStyleNormal) Value of enumeration type WdBuiltinStyle (see wordConst.tcl).

###### Return value

Returns the new text range.

###### Description

Add text to a Word document.

The text string is appended to the supplied text range with given style.

See also: AddText InsertText AppendParagraph SetRangeStyle

#### AppendParagraph [::Word]

Word, Top

Append a paragraph at the end of the document.

AppendParagraph docId spaceAfter

###### Parameters

docId | Identifier of the document.
spaceAfter | (optional, default -1) Spacing after the range.

###### Return value

Returns no value.

###### Description

Append a paragraph at the end of the document.

The spacing value may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: GetEndRange AddParagraph ::Cawt::ValueToPoints

#### AppendText [::Word]

Word, Top

Append text to a Word document.

AppendText docId text addParagraph style

###### Parameters

docId | Identifier of the document.
text | Text string to be appended.
addParagraph | (optional, default false) Add a paragraph after the text.
style | (optional, default wdStyleNormal) Value of enumeration type WdBuiltinStyle (see wordConst.tcl).

###### Return value

Returns the new text range.

###### Description

Append text to a Word document.

The text string is appended at the end of the document with given style.

See also: GetEndRange AddText InsertText AppendParagraph SetRangeStyle

#### Close [::Word]

Word, Top

Close a document without saving changes.

Close docId

###### Parameters

docId | Identifier of the document.

###### Return value

Returns no value.

###### Description

Close a document without saving changes.

Use the SaveAs method before closing, if you want to save changes.

See also: SaveAs

#### CollapseRange [::Word]

Word, Top

Collapse a text range to the start or end position.

CollapseRange rangeId direction

###### Parameters

rangeId | Identifier of the text range.
direction | (optional, default begin) Collapse direction: "begin" or "end".

###### Description

Collapse a text range to the start or end position.

After a range is collapsed, the start and end points are equal.

See also: CreateRange GetStartRange GetEndRange

#### ConfigureCaption [::Word]

Word, Top

Configure style of a caption type identified by its label identifier.

ConfigureCaption appId labelId chapterStyleLevel includeChapterNumber numberStyle separator

###### Parameters

appId | Identifier of the Word instance.
labelId | Value of enumeration type WdCaptionLabelID. Possible values: wdCaptionEquation, wdCaptionFigure, wdCaptionTable
chapterStyleLevel | 1 corresponds to Heading1, 2 corresponds to Heading2, ...
includeChapterNumber | (optional, default true) Flag indicating whether to include the chapter number.
numberStyle | (optional, default wdCaptionNumberStyleArabic) Value of enumeration type WdCaptionNumberStyle (see wordConst.tcl).
separator | (optional, default wdSeparatorHyphen) Value of enumeration type WdSeparatorType (see wordConst.tcl).

###### Return value

Returns no value.

###### Description

Configure style of a caption type identified by its label identifier.

See also: InsertCaption

#### CopyRange [::Word]

Word, Top

Copy the contents of a range into another range.

CopyRange fromRangeId toRangeId

###### Parameters

fromRangeId | Identifier of the source range.
toRangeId | Identifier of the destination range.

###### Return value

Returns no value.

###### Description

Copy the contents of a range into another range.

Note, that the contents of the destination range are overwritten.

See also: CreateRange

#### CountWords [::Word]

Word, Top

Count words contained in a Word document.

CountWords docId args

###### Parameters

docId | Identifier of the document.
args | List of key value pairs specifying the counting configure options and its values.

###### Return value

Returns a key-value list containing the found words and their corresponding count.

###### Description

Count words contained in a Word document.

Option keys:

-sortmode <string>

           Sorting mode of output list.
           Default: length. Possible values: dictionary, length.

-minlength <int>

           Only count words having more than minlength characters.
           Default: No limit.

-maxlength <int>

           Only count words having less than maxlength characters.
           Default: No limit.

-shownumbers <bool>

           If set to false, only count words which are no numbers.

This procedure is used in the CAWT application WordAbbrCheck to get a list of words contained in a Word document.

See also: ::Cawt::CountWords

#### CreateRange [::Word]

Word, Top

Create a new text range.

CreateRange docId startIndex endIndex

###### Parameters

docId | Identifier of the document.
startIndex | The start index of the range in characters.
endIndex | The end index of the range in characters.

###### Return value

Returns the identifier of the new text range.

###### Description

Create a new text range.

See also: CreateRangeAfter SelectRange GetSelectionRange

#### CreateRangeAfter [::Word]

Word, Top

Create a new text range after specified range.

CreateRangeAfter rangeId

###### Parameters

rangeId | Identifier of the text range.

###### Return value

Returns the identifier of the new text range.

###### Description

Create a new text range after specified range.

See also: CreateRange SelectRange GetSelectionRange

#### CropImage [::Word]

Word, Top

Crop an image at the four borders.

CropImage shapeId cropBottom cropTop cropLeft cropRight

###### Parameters

shapeId | Identifier of the image InlineShape.
cropBottom | (optional, default 0.0) Crop amount at the bottom border.
cropTop | (optional, default 0.0) Crop amount at the top border.
cropLeft | (optional, default 0.0) Crop amount at the left border.
cropRight | (optional, default 0.0) Crop amount at the right border.

###### Return value

Returns no value.

###### Description

Crop an image at the four borders.

The crop values may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See GetImageList for a description of InlineShapes and Shapes.

See also: GetNumImages InsertImage ScaleImage ::Cawt::ValueToPoints

#### DeleteRow [::Word]

Word, Top

Delete a row of a table.

DeleteRow tableId row

###### Parameters

tableId | Identifier of the Word table.
row | (optional, default end) Row number. Row numbering starts with 1. If not specified or "end", the last row is deleted.

###### Return value

Returns no value.

###### Description

Delete a row of a table.

See also: AddRow GetNumRows

#### DeleteTable [::Word]

Word, Top

Delete a table.

DeleteTable tableId

###### Parameters

tableId | Identifier of the Word table.

###### Return value

Returns no value.

###### Description

Delete a table.

See also: AddTable GetNumTables

#### DiffWordFiles [::Word]

Word, Top

Compare two Word files visually.

DiffWordFiles wordBaseFile wordNewFile

###### Parameters

wordBaseFile | Name of the base Word file.
wordNewFile | Name of the new Word file.

###### Return value

Returns the identifier of the new Word application instance.

###### Description

Compare two Word files visually.

The two files are opened in Word's compare mode.

See also: OpenNew

#### ExtendRange [::Word]

Word, Top

Extend the range indices of a text range.

ExtendRange rangeId startIncr endIncr

###### Parameters

rangeId | Identifier of the text range.
startIncr | (optional, default 0) Increment of the range start index.
endIncr | (optional, default 0) Increment of the range end index.

###### Return value

Returns the new extended range.

###### Description

Extend the range indices of a text range.

Increment is either an integer value or strings "begin" or "end" to use the start or end of the document.

See also: SetRangeStartIndex SetRangeEndIndex

#### FindString [::Word]

Word, Top

Find a string in a text range or a document.

FindString rangeOrDocId searchStr matchCase matchWildcards

###### Parameters

rangeOrDocId | Identifier of a text range or a document identifier.
searchStr | Search string.
matchCase | (optional, default true) Flag indicating case sensitive search.
matchWildcards | (optional, default false) Flag indicating wildcard search.

###### Return value

Returns zero, if string could not be found. Otherwise a positive integer. If the string was found, the selection is set to the found string.

###### Description

Find a string in a text range or a document.

See also: ReplaceString ReplaceByProc Search GetSelectionRange

#### FormatHeaderRow [::Word]

Word, Top

Format a row as a header row.

FormatHeaderRow tableId row startCol endCol

###### Parameters

tableId | Identifier of the Word table.
row | Row number. Row numbering starts with 1.
startCol | Column number of formatting start. Column numbering starts with 1.
endCol | Column number of formatting end. Column numbering starts with 1.

###### Return value

Returns no value.

###### Description

Format a row as a header row.

The cell values of a header are formatted as bold text with both vertical and horizontal centered alignment.

See also: SetHeaderRow SetHeadingFormat

#### GetBookmarkName [::Word]

Word, Top

Get the name of a bookmark.

GetBookmarkName bookmarkId

###### Parameters

bookmarkId | Identifier of the boormark.

###### Return value

Returns the name of the bookmark.

###### Description

Get the name of a bookmark.

See also: AddBookmark SetLinkToBookmark

#### GetCellRange [::Word]

Word, Top

Return a cell of a Word table as a range.

GetCellRange tableId row col

###### Parameters

tableId | Identifier of the Word table.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.

###### Return value

Returns a range consisting of 1 cell of a Word table.

###### Description

Return a cell of a Word table as a range.

See also: GetRowRange GetColumnRange

#### GetCellValue [::Word]

Word, Top

Return the value of a Word table cell.

GetCellValue tableId row col

###### Parameters

tableId | Identifier of the Word table.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.

###### Return value

Returns the value of the specified cell as a string.

###### Description

Return the value of a Word table cell.

See also: SetCellValue IsValidCell

#### GetColumnRange [::Word]

Word, Top

Return a column of a Word table as a selection.

GetColumnRange tableId col

###### Parameters

tableId | Identifier of the Word table.
col | Column number. Column numbering starts with 1.

###### Return value

Returns a selection consisting of all cells of a column.

###### Description

Return a column of a Word table as a selection.

Note, that a selection is returned and not a range, because columns do not have a range property.

See also: GetCellRange GetRowRange

#### GetColumnValues [::Word]

Word, Top

Return column values of a Word table as a Tcl list.

GetColumnValues tableId col startRow numVals

###### Parameters

tableId | Identifier of the Word table.
col | Column number. Column numbering starts with 1.
startRow | (optional, default 1) Row number of start. Row numbering starts with 1.
numVals | (optional, default 0) Negative or zero: All available column values are returned. Positive: Only numVals values of the column are returned.

###### Return value

Returns the values of the specified column or column range as a Tcl list.

###### Description

Return column values of a Word table as a Tcl list.

See also: SetColumnValues GetRowValues GetCellValue

#### GetCompatibilityMode [::Word]

Word, Top

Return the compatibility version of a Word application.

GetCompatibilityMode appId version

###### Parameters

appId | Identifier of the Word instance.
version | (optional, default ) Word version number.

###### Return value

Returns the compatibility mode of the current Word application, if version is not specified or the empty string. If version is a valid Word version as returned by GetVersion, the corresponding compatibility mode is returned.

###### Description

Return the compatibility version of a Word application.

Note: The compatibility mode is a value of enumeration WdCompatibilityMode.

See also: GetVersion GetExtString

#### GetDocumentId [::Word]

Word, Top

Get the document identifier of a Word component.

GetDocumentId componentId

###### Parameters

componentId | The identifier of a Word component.

###### Return value

Returns the document identifier of a Word component.

###### Description

Get the document identifier of a Word component.

Word components having the Document property are ex. ranges, panes.

See also: GetNumDocuments GetDocumentName

#### GetDocumentIdByIndex [::Word]

Word, Top

Find a document by its index.

GetDocumentIdByIndex appId index

###### Parameters

appId | Identifier of the Word instance.
index | Index of the document to find.

###### Return value

Returns the identifier of the found document. If the index is out of bounds an error is thrown.

###### Description

Find a document by its index.

See also: GetNumDocuments GetDocumentId GetDocumentName

#### GetDocumentName [::Word]

Word, Top

Get the name of a document.

GetDocumentName docId

###### Parameters

docId | Identifier of the document.

###### Return value

Returns the name of the document (i.e. the full path name of the corresponding Word file) as a string.

###### Description

Get the name of a document.

See also: GetNumDocuments GetDocumentId

#### GetEndRange [::Word]

Word, Top

Return the text range representing the end of the document.

GetEndRange docId

###### Parameters

docId | Identifier of the document.

###### Return value

Returns the text range representing the end of the document.

###### Description

Return the text range representing the end of the document.

Note: This corresponds to the built-in bookmark \endofdoc.

          The end range of an empty document is (0, 0), although
          GetNumCharacters returns 1.

See also: GetSelectionRange GetStartRange GetNumCharacters

#### GetEnum [::Word]

Word, Top

Get numeric value of an enumeration.

GetEnum enumOrString

###### Parameters

enumOrString | Enumeration name

###### Return value

Returns the numeric value of an enumeration.

###### Description

Get numeric value of an enumeration.

See also: GetEnumName GetEnumTypes GetEnumVal GetEnumNames

#### GetEnumName [::Word]

Word, Top

Get name of a given enumeration type and numeric value.

GetEnumName enumType enumVal

###### Parameters

enumType | Enumeration type
enumVal | Enumeration numeric value.

###### Return value

Returns a list of names of a given enumeration type.

###### Description

Get name of a given enumeration type and numeric value.

See also: GetEnumNames GetEnumTypes GetEnumVal GetEnum

#### GetEnumNames [::Word]

Word, Top

Get names of a given enumeration type.

GetEnumNames enumType

###### Parameters

enumType | Enumeration type

###### Return value

Returns a list of names of a given enumeration type.

###### Description

Get names of a given enumeration type.

See also: GetEnumName GetEnumTypes GetEnumVal GetEnum

#### GetEnumTypes [::Word]

Word, Top

Get available enumeration types.

GetEnumTypes

###### Return value

Returns a list of available enumeration types.

###### Description

Get available enumeration types.

See also: GetEnumName GetEnumNames GetEnumVal GetEnum

#### GetEnumVal [::Word]

Word, Top

Get numeric value of an enumeration name.

GetEnumVal enumName

###### Parameters

enumName | Enumeration name

###### Return value

Returns the numeric value of an enumeration name.

###### Description

Get numeric value of an enumeration name.

See also: GetEnumName GetEnumTypes GetEnumNames GetEnum

#### GetExtString [::Word]

Word, Top

Return the default extension of a Word file.

GetExtString appId

###### Parameters

appId | Identifier of the Word instance.

###### Return value

Returns the default extension of a Word file.

###### Description

Return the default extension of a Word file.

Starting with Word 12 (2007) this is the string ".docx". In previous versions it was ".doc".

See also: GetCompatibilityMode GetVersion ::Office::GetOfficeType

#### GetImageId [::Word]

Word, Top

Find an image by its index or name.

GetImageId docId indexOrName

###### Parameters

docId | Identifier of the document.
indexOrName | Index or name of the image to find.

###### Return value

Returns the identifier of the found InlineShape.

###### Description

Find an image by its index or name.

Image names are supported since Word 2010. If your Word version is older, an error is thrown.

If the index is out of bounds or the specified name does not exists, an error is thrown.

See GetImageList for a description of InlineShapes and Shapes.

See also: GetNumImages GetImageList InsertImage ReplaceImage SetImageName

#### GetImageList [::Word]

Word, Top

Get a list of images of a Word document.

GetImageList docId args

###### Parameters

docId | Identifier of the document.
args | List of key value pairs specifying image type options and its values.

###### Return value

Returns a list of shape identifiers of the images of a Word document. Note, that if both InlineShapes and Shapes are returned in one list, all InlineShapes come first, followed by the Shapes.

###### Description

Get a list of images of a Word document.

Option keys:

-inlineshapes <bool>

        Consider InlineShapes as images. Default value is true.

-shapes <bool>

        Consider Shapes as images. Default value is true.

Images are either InlineShapes of enumeration WdInlineShapeType (wdInlineShapePicture, wdInlineShapeLinkedPicture) or Shapes of enumeration MsoShapeType (msoInlinePicture, msoLinkedPicture).

See also: GetNumImages InsertImage ReplaceImage GetImageId SetImageName

#### GetImageName [::Word]

Word, Top

Return the name of an image.

GetImageName shapeId

###### Parameters

shapeId | Identifier of the image InlineShape or Shape.

###### Return value

Returns the name of an image.

###### Description

Return the name of an image.

Image names are supported since Word 2010. If your Word version is older, an error is thrown.

See GetImageList for a description of InlineShapes and Shapes.

See also: GetNumImages SetImageName InsertImage GetImageId GetImageList

#### GetListGalleryId [::Word]

Word, Top

Get one of the 3 predefined list galleries.

GetListGalleryId appId galleryType

###### Parameters

appId | Identifier of the Word instance.
galleryType | Value of enumeration type WdListGalleryType (see wordConst.tcl).

###### Return value

Returns the identifier of the specified list gallery.

###### Description

Get one of the 3 predefined list galleries.

See also: GetListTemplateId InsertList

#### GetListTemplateId [::Word]

Word, Top

Get one of the 7 predefined list templates.

GetListTemplateId galleryId listType

###### Parameters

galleryId | Identifier of the Word gallery.
listType | Value of enumeration type WdListType (see wordConst.tcl)

###### Return value

Returns the identifier of the specified list template.

###### Description

Get one of the 7 predefined list templates.

See also: GetListGalleryId InsertList

#### GetMatrixValues [::Word]

Word, Top

Return table values as a matrix.

GetMatrixValues tableId row1 col1 row2 col2

###### Parameters

tableId | Identifier of the Word table.
row1 | Row number of upper-left corner of the cell range.
col1 | Column number of upper-left corner of the cell range.
row2 | Row number of lower-right corner of the cell range.
col2 | Column number of lower-right corner of the cell range.

###### Return value

Returns table values as a matrix.

###### Description

Return table values as a matrix.

See also: SetMatrixValues

#### GetNumCharacters [::Word]

Word, Top

Return the number of characters in a Word document.

GetNumCharacters docId

###### Parameters

docId | Identifier of the document.

###### Return value

Returns the number of characters in a Word document.

###### Description

Return the number of characters in a Word document.

See also: GetNumDocuments GetNumTables GetNumCharacters

#### GetNumColumns [::Word]

Word, Top

Return the number of columns of a Word table.

GetNumColumns tableId

###### Parameters

tableId | Identifier of the Word table.

###### Return value

Returns the number of columns of a Word table.

###### Description

Return the number of columns of a Word table.

See also: GetNumRows GetNumTables

#### GetNumDocuments [::Word]

Word, Top

Return the number of documents in a Word application.

GetNumDocuments appId

###### Parameters

appId | Identifier of the Word instance.

###### Return value

Returns the number of documents in a Word application.

###### Description

Return the number of documents in a Word application.

See also: AddDocument OpenDocument

#### GetNumImages [::Word]

Word, Top

Return the number of images of a Word document.

GetNumImages docId useInlineShapesOnly

###### Parameters

docId | Identifier of the document.
useInlineShapesOnly | (optional, default true) Only consider InlineShapes as images.

###### Return value

Returns the number of images of a Word document.

###### Description

Return the number of images of a Word document.

See GetImageList for a description of InlineShapes and Shapes.

See also: InsertImage ReplaceImage GetImageId GetImageList SetImageName

#### GetNumRows [::Word]

Word, Top

Return the number of rows of a Word table.

GetNumRows tableId

###### Parameters

tableId | Identifier of the Word table.

###### Return value

Returns the number of rows of a Word table.

###### Description

Return the number of rows of a Word table.

See also: GetNumColumns GetNumTables

#### GetNumTables [::Word]

Word, Top

Return the number of tables of a Word document.

GetNumTables docId

###### Parameters

docId | Identifier of the document.

###### Return value

Returns the number of tables of a Word document.

###### Description

Return the number of tables of a Word document.

See also: AddTable GetNumRows GetNumColumns

#### GetPageSetup [::Word]

Word, Top

Get page setup values.

GetPageSetup docId args

###### Parameters

docId | Identifier of the document.
args | List of keys specifying the page setup values to be retrieved.

###### Return value

Returns the specified page setup values as a list.

###### Description

Get page setup values.

Option keys:

-top

          Get the size of the top margin.

-bottom

          Get the size of the bottom margin.

-left

          Get the size of the left margin.

-right

          Get the size of the right margin.

-footer

          Get the size of the footer margin.

-header

          Get the size of the header margin.

-height

          Get the height of the page.

-width

          Get the width of the page.

-usableheight

          Get the usable height of the page, i.e. height - top - bottom.

-usablewidth

          Get the usable width of the page, i.e. width - left - right.

-centimeter

          Get the values in centimeters.

-inch

          Get the values in inches.

The values are returned as points, if no unit option is specified.

Example:

        lassign [GetPageSetup $docId -top -left -inch] top left
        returns the top and left margins in inches.

See also: ::Cawt::PointsToCentiMeters ::Cawt::PointsToInches

#### GetRangeEndIndex [::Word]

Word, Top

Return the end index of a text range.

GetRangeEndIndex rangeId

###### Parameters

rangeId | Identifier of the text range.

###### Return value

Returns the end index of a text range.

###### Description

Return the end index of a text range.

See also: GetRangeStartIndex PrintRange

#### GetRangeInformation [::Word]

Word, Top

Get information about a text range.

GetRangeInformation rangeId type

###### Parameters

rangeId | Identifier of the text range.
type | Value of enumeration type WdInformation (see wordConst.tcl).

###### Return value

Returns the range information associated with the supplied type.

###### Description

Get information about a text range.

See also: GetStartRange GetEndRange PrintRange

#### GetRangeStartIndex [::Word]

Word, Top

Return the start index of a text range.

GetRangeStartIndex rangeId

###### Parameters

rangeId | Identifier of the text range.

###### Return value

Returns the start index of a text range.

###### Description

Return the start index of a text range.

See also: GetRangeEndIndex PrintRange

#### GetRowId [::Word]

Word, Top

Return identifier of a Word table row.

GetRowId tableId row

###### Parameters

tableId | Identifier of the Word table.
row | Row number. Row numbering starts with 1. If set to "end", the last row of the table is used.

###### Return value

Returns the identifier of the specified row.

###### Description

Return identifier of a Word table row.

See also: GetRowRange GetCellRange GetColumnRange

#### GetRowRange [::Word]

Word, Top

Return rows of a Word table as a range.

GetRowRange tableId row1 row2

###### Parameters

tableId | Identifier of the Word table.
row1 | Row range start number.
row2 | (optional, default ) Row range end number. If not specified, only row1 is used. If set to "end", the last row of the table is used.

###### Return value

Returns a range consisting of all cells of the specified rows.

###### Description

Return rows of a Word table as a range.

Row numbering starts with 1.

See also: GetRowId GetCellRange GetColumnRange

#### GetRowValues [::Word]

Word, Top

Return row values of a Word table as a Tcl list.

GetRowValues tableId row startCol numVals

###### Parameters

tableId | Identifier of the Word table.
row | Row number. Row numbering starts with 1.
startCol | (optional, default 1) Column number of start. Column numbering starts with 1.
numVals | (optional, default 0) Negative or zero: All available row values are returned. Positive: Only numVals values of the row are returned.

###### Return value

Returns the values of the specified row or row range as a Tcl list.

###### Description

Return row values of a Word table as a Tcl list.

See also: SetRowValues GetColumnValues GetCellValue

#### GetSelectionRange [::Word]

Word, Top

Return the text range representing the current selection.

GetSelectionRange docId

###### Parameters

docId | Identifier of the document.

###### Return value

Returns the text range representing the current selection.

###### Description

Return the text range representing the current selection.

See also: GetStartRange GetEndRange SelectRange

#### GetStartRange [::Word]

Word, Top

Return a text range representing the start of the document.

GetStartRange docId

###### Parameters

docId | Identifier of the document.

###### Return value

Returns a text range representing the start of the document.

###### Description

Return a text range representing the start of the document.

See also: CreateRange GetSelectionRange GetEndRange

#### GetTableIdByIndex [::Word]

Word, Top

Find a table by its index.

GetTableIdByIndex docId index

###### Parameters

docId | Identifier of the document.
index | Index of the table to find.

###### Return value

Returns the identifier of the found table. If the index is out of bounds an error is thrown.

###### Description

Find a table by its index.

See also: GetTableIdByName GetNumTables

#### GetTableIdByName [::Word]

Word, Top

Find table(s) by its name.

GetTableIdByName docId name

###### Parameters

docId | Identifier of the document.
name | Name of the table(s) to find.

###### Return value

Returns a list of identifiers of the found table(s). If no tables with given name exist, an empty list is returned.

###### Description

Find table(s) by its name.

Table names are supported since Word 2010. If your Word version is older, an error is thrown.

See also: GetTableIdByIndex GetNumTables

#### GetTableName [::Word]

Word, Top

Return the name of a table.

GetTableName tableId

###### Parameters

tableId | Identifier of the Word table.

###### Return value

Returns the name of a table.

###### Description

Return the name of a table.

Table names are supported since Word 2010. If your Word version is older, an error is thrown.

See also: SetTableName GetNumTables AddTable

#### GetVersion [::Word]

Word, Top

Return the version of a Word application.

GetVersion objId useString

###### Parameters

objId | Identifier of a Word object instance.
useString | (optional, default false) true: Return the version name (ex. "Word 2000"). false: Return the version number (ex. "9.0").

###### Return value

Returns the version of a Word application.

###### Description

Return the version of a Word application.

Both version name and version number are returned as strings. Version number is in a format, so that it can be evaluated as a floating point number.

See also: GetCompatibilityMode GetExtString

#### InsertCaption [::Word]

Word, Top

Insert a caption into a range of a document.

InsertCaption rangeId labelId text pos

###### Parameters

rangeId | Identifier of the text range.
labelId | Value of enumeration type WdCaptionLabelID. Possible values: wdCaptionEquation, wdCaptionFigure, wdCaptionTable
text | Text of the caption.
pos | (optional, default wdCaptionPositionBelow) Value of enumeration type WdCaptionPosition (see wordConst.tcl).

###### Return value

Returns the new extended range.

###### Description

Insert a caption into a range of a document.

See also: ConfigureCaption InsertFile InsertImage InsertList InsertText

#### InsertFile [::Word]

Word, Top

Insert a file into a Word document.

InsertFile rangeId fileName pasteFormat

###### Parameters

rangeId | Identifier of the text range.
fileName | Name of the file to insert.
pasteFormat | (optional, default ) Value of enumeration type WdRecoveryType (see wordConst.tcl).

###### Return value

Returns no value.

###### Description

Insert a file into a Word document.

Insert an external file a the text range identified by rangeId. If pasteFormat is not specified or an empty string, the method InsertFile is used. Otherwise the external file is opened in a new Word document, copied to the clipboard and pasted into the text range. For pasting the PasteAndFormat method is used, so it is possible to merge the new text from the external file into the Word document in different ways.

See also: SetHyperlink InsertCaption InsertImage InsertList InsertText

#### InsertImage [::Word]

Word, Top

Insert an image into a range of a document.

InsertImage rangeId imgFileName linkToFile saveWithDoc

###### Parameters

rangeId | Identifier of the text range.
imgFileName | File name of the image.
linkToFile | (optional, default false) Insert a link to the image file.
saveWithDoc | (optional, default true) Embed the image into the document.

###### Return value

Returns the identifier of the inserted image as an InlineShape.

###### Description

Insert an image into a range of a document.

See GetImageList for a description of InlineShapes and Shapes.

See also: GetNumImages ScaleImage CropImage InsertFile InsertCaption InsertList InsertText

#### InsertList [::Word]

Word, Top

Insert a Word list.

InsertList rangeId stringList galleryType listType

###### Parameters

rangeId | Identifier of the text range.
stringList | List of text strings building up the Word list.
galleryType | (optional, default wdBulletGallery) Value of enumeration type WdListGalleryType (see wordConst.tcl).
listType | (optional, default wdListListNumOnly) Value of enumeration type WdListType (see wordConst.tcl)

###### Return value

Returns the range of the Word list.

###### Description

Insert a Word list.

See also: GetListGalleryId GetListTemplateId InsertCaption InsertFile InsertImage InsertText

#### InsertText [::Word]

Word, Top

Insert text in a Word document.

InsertText docId text addParagraph style

###### Parameters

docId | Identifier of the document.
text | Text string to be inserted.
addParagraph | (optional, default false) Add a paragraph after the text.
style | (optional, default wdStyleNormal) Value of enumeration type WdBuiltinStyle (see wordConst.tcl).

###### Return value

Returns the new text range.

###### Description

Insert text in a Word document.

The text string is inserted at the start of the document with given style.

See also: AddText AppendText AddParagraph SetRangeStyle InsertCaption InsertFile InsertImage InsertList

#### IsInlineShape [::Word]

Word, Top

Borders is a property of the Word InlineShape class, but not of class Shape.

IsInlineShape objId

###### Parameters

objId |

###### Description

Borders is a property of the Word InlineShape class, but not of class Shape.

#### IsValidCell [::Word]

Word, Top

Check, if a Word table cell is valid.

IsValidCell tableId row col

###### Parameters

tableId | Identifier of the Word table.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.

###### Return value

Returns true, if the cell is valid, otherwise false.

###### Description

Check, if a Word table cell is valid.

See also: GetCellValue

#### IsVisible [::Word]

Word, Top

Check the visibility of a Word application window.

IsVisible appId

###### Parameters

appId | Identifier of the Word instance.

###### Return value

Returns true, if the Word application windows is visible.

###### Description

Check the visibility of a Word application window.

See also: Open OpenNew Visible

#### MergeCells [::Word]

Word, Top

Merge a range of cells.

MergeCells tableId row1 col1 row2 col2

###### Parameters

tableId | Identifier of the Word table.
row1 | Range start row number. Row numbering starts with 1.
col1 | Range start column number. Column numbering starts with 1.
row2 | Range end row number. If set to "end", the last row of the table is used.
col2 | Range end column number. If set to "end", the last column of the table is used.

###### Return value

Returns the range identifier of the merged cells.

###### Description

Merge a range of cells.

See also: SetRangeMergeCells SelectRange

#### Open [::Word]

Word, Top

Open a Word instance. Use an already running instance, if available.

Open visible width height

###### Parameters

visible | (optional, default true) true: Show the application window. false: Hide the application window.
width | (optional, default -1) Width of the application window. If negative, open with last used width.
height | (optional, default -1) Height of the application window. If negative, open with last used height.

###### Return value

Returns the identifier of the Word application instance.

###### Description

Open a Word instance. Use an already running instance, if available.

See also: OpenNew Quit Visible

#### OpenDocument [::Word]

Word, Top

Open a document, i.e. load a Word file.

OpenDocument appId fileName readOnly

###### Parameters

appId | Identifier of the Word instance.
fileName | Name of the Word file.
readOnly | (optional, default false) true: Open the document in read-only mode. false: Open the document in read-write mode.

###### Return value

Returns the identifier of the opened document. If the document was already open, activate that document and return the identifier to that document.

###### Description

Open a document, i.e. load a Word file.

See also: AddDocument

#### OpenNew [::Word]

Word, Top

Open a new Word instance.

OpenNew visible width height

###### Parameters

visible | (optional, default true) true: Show the application window. false: Hide the application window.
width | (optional, default -1) Width of the application window. If negative, open with last used width.
height | (optional, default -1) Height of the application window. If negative, open with last used height.

###### Return value

Returns the identifier of the new Word application instance.

###### Description

Open a new Word instance.

See also: Open Quit Visible

#### PrintRange [::Word]

Word, Top

Print the indices of a text range.

PrintRange rangeId msg

###### Parameters

rangeId | Identifier of the text range.
msg | (optional, default Range: ) String printed in front of the indices.

###### Return value

Returns no value.

###### Description

Print the indices of a text range.

The range identifiers are printed onto standard output.

See also: GetRangeStartIndex GetRangeEndIndex

#### Quit [::Word]

Word, Top

Quit a Word instance.

Quit appId showAlert

###### Parameters

appId | Identifier of the Word instance.
showAlert | (optional, default true) true: Show an alert window, if there are unsaved changes. false: Quit without saving any changes.

###### Return value

Returns no value.

###### Description

Quit a Word instance.

See also: Open OpenNew

#### ReplaceByProc [::Word]

Word, Top

Replace a string in a text range. Procedural case.

ReplaceByProc rangeId str func args

###### Parameters

rangeId | Identifier of the text range.
str | Search string.
func | Replacement procedure.
args | Arguments for replacement procedure.

###### Return value

Returns no value.

###### Description

Replace a string in a text range. Procedural case.

Search for string "str" in the range "rangeId". For each occurence found, call procedure "func" with the range of the found occurence and additional parameters specified in "args". The procedures which can be used for "func" must therefore have the following signature: proc SetRangeXYZ rangeId param1 param2 ...

See test script Word-04-Find.tcl for an example.

See also: FindString ReplaceString

#### ReplaceImage [::Word]

Word, Top

Replace an existing image.

ReplaceImage shapeId imgFileName args

###### Parameters

shapeId | Identifier of the image InlineShape or Shape.
imgFileName | File name of the new image (as absolute path).
args | List of key value pairs specifying the replacement options and its values.

###### Return value

Returns the identifier of the new image.

###### Description

Replace an existing image.

Option keys:

-keepsize <bool>

        Keep original image size. Default value is false.

See GetImageList for a description of InlineShapes and Shapes.

Note, that replacing Shape images does not work correctly yet. Images are replaced, but the layout is disturbed.

See also: InsertImage GetImageList GetNumImages SetImageName

#### ReplaceString [::Word]

Word, Top

Replace a string in a text range or a document. Simple case.

ReplaceString rangeOrDocId searchStr replaceStr howMuch matchCase matchWildcards

###### Parameters

rangeOrDocId | Identifier of a text range or a document identifier.
searchStr | Search string.
replaceStr | Replacement string.
howMuch | (optional, default one) "one" to replace first occurence only. "all" to replace all occurences.
matchCase | (optional, default true) Flag indicating case sensitive search.
matchWildcards | (optional, default false) Flag indicating wildcard search.

###### Return value

Returns zero, if string could not be found and replaced. Otherwise a positive integer.

###### Description

Replace a string in a text range or a document. Simple case.

See also: FindString ReplaceByProc Search

#### SaveAs [::Word]

Word, Top

Save a document to a Word file.

SaveAs docId fileName fmt

###### Parameters

docId | Identifier of the document to save.
fileName | Name of the Word file.
fmt | (optional, default ) Value of enumeration type WdSaveFormat (see wordConst.tcl). If not given or the empty string, the file is stored in the native format corresponding to the used Word version.

###### Return value

Returns no value.

###### Description

Save a document to a Word file.

See also: SaveAsPdf

#### SaveAsPdf [::Word]

Word, Top

Save a document to a PDF file.

SaveAsPdf docId fileName

###### Parameters

docId | Identifier of the document to export.
fileName | Name of the PDF file.

###### Return value

Returns no value.

###### Description

Save a document to a PDF file.

PDF export is supported since Word 2007. If your Word version is older an error is thrown.

Note, that for Word 2007 you need the Microsoft Office Add-in "Microsoft Save as PDF or XPS" available from http://www.microsoft.com/en-us/download/details.aspx?id=7

See also: SaveAs

#### ScaleImage [::Word]

Word, Top

Scale an image.

ScaleImage shapeId scaleWidth scaleHeight

###### Parameters

shapeId | Identifier of the image InlineShape.
scaleWidth | Horizontal scale factor.
scaleHeight | Vertical scale factor.

###### Return value

Returns no value.

###### Description

Scale an image.

The scale factors are floating point values. 1.0 means no scaling.

See GetImageList for a description of InlineShapes and Shapes.

See also: GetNumImages InsertImage ReplaceImage CropImage

#### ScreenUpdate [::Word]

Word, Top

Toggle the screen updating of a Word application window.

ScreenUpdate appId onOff

###### Parameters

appId | Identifier of the Word instance.
onOff | true: Update the application window. false: Do not update the application window.

###### Return value

Returns no value.

###### Description

Toggle the screen updating of a Word application window.

See also: Visible IsVisible

#### Search [::Word]

Word, Top

Search or replace a string in a text range or a document. Generic case.

Search rangeOrDocId searchStr args

###### Parameters

rangeOrDocId | Identifier of a text range or a document identifier.
searchStr | Search string.
args | List of key value pairs specifying the search options and its values.

###### Return value

Returns zero, if string could not be found and replaced. Otherwise a positive integer.

###### Description

Search or replace a string in a text range or a document. Generic case.

Option keys:

See the Word reference documentation regarding Find.Execute at https://msdn.microsoft.com/en-us/library/office/ff193977.aspx for more details.

-matchcase

        Search in case sensitive mode. Value is of type bool.

-matchwholeword

        Search entire words only. Value is of type bool.

-matchwildcards

        Search with wild cards. Value is of type bool.

-matchsoundslike

        Search for strings that sound similar. Value is of type bool.

-matchallwordforms

        Search all forms of the search string. Value is of type bool.

-forward

        Search towards end of document. Value is of type bool.

-wrap

        Search wrap mode. Value is of type WdFindWrap (wdFindAsk, wdFindContinue, wdFindStop).

-format

        Search operation uses formatting in addition to the search string. Value is of type bool.

-replacewith

        Replacement text. Value is of type string.

-replace

        Number of replacements. Value is of type WdReplace(wdReplaceNone, wdReplaceOne, wdReplaceAll).

-matchkashida

        Match text with matching kashidas in an Arabic-language document. Value is of type bool.

-matchdiacritics

        Match text with matching diacritics in a right-to-left language document. Value is of type bool.

-matchalefhamza

        Match text with matching alef hamzas in an Arabic-language document. Value is of type bool.

-matchcontrol

        Match text with matching bidirectional control characters in a right-to-left language document.
        Value is of type bool.

-matchprefix

        Match words beginning with the search string. Value is of type bool.

-matchsuffix

        Match words ending with the search string. Value is of type bool.

-matchphrase

        Ignores all white space and control characters between words. Value is of type bool.

-ignorespace

         Ignore all white space between words. Value is of type bool.

-ignorepunct

         Ignore all punctuation characters between words. Value is of type bool.

See also: FindString ReplaceString ReplaceByProc

#### SelectRange [::Word]

Word, Top

Select a text range.

SelectRange rangeId

###### Parameters

rangeId | Identifier of the text range.

###### Return value

Returns no value.

###### Description

Select a text range.

See also: GetSelectionRange

#### SetCellValue [::Word]

Word, Top

Set the value of a Word table cell.

SetCellValue tableId row col val

###### Parameters

tableId | Identifier of the Word table.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.
val | String value of the cell.

###### Return value

Returns no value.

###### Description

Set the value of a Word table cell.

See also: GetCellValue SetRowValues SetMatrixValues

#### SetCellVerticalAlignment [::Word]

Word, Top

Set the vertical alignment of a Word table cell.

SetCellVerticalAlignment tableId row col align

###### Parameters

tableId | Identifier of the Word table.
row | Row number. Row numbering starts with 1.
col | Column number. Column numbering starts with 1.
align | Value of enumeration type WdCellVerticalAlignment (see wordConst.tcl) or any of the following strings: top, bottom, center.

###### Return value

Returns no value.

###### Description

Set the vertical alignment of a Word table cell.

See also: SetCellValue SetRangeHorizontalAlignment

#### SetColumnsWidth [::Word]

Word, Top

Set the width of a range of table columns.

SetColumnsWidth tableId startCol endCol width

###### Parameters

tableId | Identifier of the Word table.
startCol | Range start column number. Column numbering starts with 1.
endCol | Range end column number. Column numbering starts with 1.
width | Column width.

###### Return value

Returns no value.

###### Description

Set the width of a range of table columns.

The size value may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: SetColumnWidth ::Cawt::ValueToPoints

#### SetColumnValues [::Word]

Word, Top

Insert column values into a Word table.

SetColumnValues tableId col valList startRow numVals

###### Parameters

tableId | Identifier of the Word table.
col | Column number. Column numbering starts with 1.
valList | List of values to be inserted.
startRow | (optional, default 1) Row number of insertion start. Row numbering starts with 1.
numVals | (optional, default 0) Negative or zero: All list values are inserted. Positive: numVals rows are filled with the list values (starting at list index 0).

###### Return value

Returns no value.

###### Description

Insert column values into a Word table.

See also: GetColumnValues SetRowValues SetCellValue

#### SetColumnWidth [::Word]

Word, Top

Set the width of a table column.

SetColumnWidth tableId col width

###### Parameters

tableId | Identifier of the Word table.
col | Column number. Column numbering starts with 1.
width | Column width.

###### Return value

Returns no value.

###### Description

Set the width of a table column.

The size value may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: SetColumnsWidth ::Cawt::ValueToPoints

#### SetCompatibilityMode [::Word]

Word, Top

Set the compatibility mode of a document.

SetCompatibilityMode docId mode

###### Parameters

docId | Identifier of the document.
mode | (optional, default wdWord2010) Compatibility mode of the document. Value of enumeration type WdCompatibilityMode (see wordConst.tcl).

###### Return value

Returns no value.

###### Description

Set the compatibility mode of a document.

Available only for Word 2010 and up.

See also: GetCompatibilityMode

#### SetContentControlDropdown [::Word]

Word, Top

SetContentControlDropdown controlId placeholderText keyValueList

###### Parameters

controlId |
placeholderText |
keyValueList |

#### SetContentControlText [::Word]

Word, Top

SetContentControlText controlId placeholderText

###### Parameters

controlId |
placeholderText |

#### SetHeaderRow [::Word]

Word, Top

Insert row values into a Word table and format as a header row.

SetHeaderRow tableId headerList row startCol

###### Parameters

tableId | Identifier of the Word table.
headerList | List of values to be inserted as header.
row | (optional, default 1) Row number. Row numbering starts with 1.
startCol | (optional, default 1) Column number of insertion start. Column numbering starts with 1.

###### Return value

Returns no value. If headerList is an empty list, an error is thrown.

###### Description

Insert row values into a Word table and format as a header row.

See also: SetRowValues FormatHeaderRow SetHeadingFormat

#### SetHeadingFormat [::Word]

Word, Top

Set the HeadingFormat flag of table rows.

SetHeadingFormat tableId onOff args

###### Parameters

tableId | Identifier of the Word table.
onOff | Heading format flag.
args | List of row numbers for which the heading format flag should be set. Row numbering starts with 1. If no row numbers are specified, row number 1 is used.

###### Return value

Returns no value.

###### Description

Set the HeadingFormat flag of table rows.

If onOff is set to true, the specified row is formatted as a table heading. Rows formatted as table headings are repeated when a table spans more than one page.

See also: SetHeaderRow FormatHeaderRow

#### SetHyperlink [::Word]

Word, Top

Insert an external hyperlink into a Word document.

SetHyperlink rangeId link textDisplay

###### Parameters

rangeId | Identifier of the text range.
link | URL of the hyperlink.
textDisplay | (optional, default ) Text to be displayed instead of the URL.

###### Return value

Returns no value.

###### Description

Insert an external hyperlink into a Word document.

# URL's are specified as strings: file://myLinkedFile specifies a link to a local file. http://myLinkedWebpage specifies a link to a web address.

See also: SetHyperlinkToFile SetLinkToBookmark SetInternalHyperlink

#### SetHyperlinkToFile [::Word]

Word, Top

Insert a hyperlink to a file into a Word document.

SetHyperlinkToFile rangeId fileName textDisplay

###### Parameters

rangeId | Identifier of the text range.
fileName | Path name of the linked file.
textDisplay | (optional, default ) Text to be displayed instead of the file name.

###### Return value

Returns no value.

###### Description

Insert a hyperlink to a file into a Word document.

See also: SetHyperlink SetLinkToBookmark SetInternalHyperlink

#### SetImageName [::Word]

Word, Top

Set the name of an image.

SetImageName shapeId name

###### Parameters

shapeId | Identifier of the image InlineShape or Shape.
name |

###### Return value

Returns no value.

###### Description

Set the name of an image.

Image names are supported since Word 2010. If your Word version is older, an error is thrown.

See GetImageList for a description of InlineShapes and Shapes.

See also: GetNumImages GetImageName InsertImage GetImageId GetImageList

#### SetInternalHyperlink [::Word]

Word, Top

Insert an internal hyperlink into a Word document.

SetInternalHyperlink rangeId subAddress textDisplay

###### Parameters

rangeId | Identifier of the text range.
subAddress | Internal reference.
textDisplay | (optional, default ) Text to be displayed instead of the URL.

###### Return value

Returns no value.

###### Description

Insert an internal hyperlink into a Word document.

See also: SetLinkToBookmark SetHyperlink SetHyperlinkToFile

#### SetLinkToBookmark [::Word]

Word, Top

Insert an internal link to a bookmark into a Word document.

SetLinkToBookmark rangeId bookmarkId textDisplay

###### Parameters

rangeId | Identifier of the text range.
bookmarkId | Identifier of the bookmark to link to.
textDisplay | (optional, default ) Text to be displayed instead of the bookmark name.

###### Return value

Returns no value.

###### Description

Insert an internal link to a bookmark into a Word document.

See also: AddBookmark GetBookmarkName SetHyperlink SetInternalHyperlink

#### SetMatrixValues [::Word]

Word, Top

Insert matrix values into a Word table.

SetMatrixValues tableId matrixList startRow startCol

###### Parameters

tableId | Identifier of the Word table.
matrixList | Matrix with table data.
startRow | (optional, default 1) Row number of insertion start. Row numbering starts with 1.
startCol | (optional, default 1) Column number of insertion start. Column numbering starts with 1.

###### Return value

Returns no value.

###### Description

Insert matrix values into a Word table.

The matrix data must be stored as a list of lists. Each sub-list contains the values for the row values. The main (outer) list contains the rows of the matrix.

Example:

        { { R1_C1 R1_C2 R1_C3 } { R2_C1 R2_C2 R2_C3 } }

See also: GetMatrixValues

#### SetRangeBackgroundColor [::Word]

Word, Top

Set the background color of a table cell range.

SetRangeBackgroundColor rangeId args

###### Parameters

rangeId | Identifier of the cell range.
args | Text color.

###### Return value

Returns no value.

###### Description

Set the background color of a table cell range.

Color value may be specified in a format acceptable by procedure ::Cawt::GetColor, i.e. color name, hexadecimal string, Office color number or a list of 3 integer RGB values.

Note: This functionality is very slow with large tables ( > 100 rows).

See also: SetRangeBackgroundColorByEnum SetRangeHighlightColorByEnum ::Cawt::GetColor

#### SetRangeBackgroundColorByEnum [::Word]

Word, Top

Set the background color of a table cell range.

SetRangeBackgroundColorByEnum rangeId colorEnum

###### Parameters

rangeId | Identifier of the cell range.
colorEnum | Value of enumeration type WdColor (see wordConst.tcl).

###### Return value

Returns no value.

###### Description

Set the background color of a table cell range.

Note: This functionality is very slow with large tables ( > 100 rows).

See also: SetRangeBackgroundColor SetRangeHighlightColorByEnum

#### SetRangeEndIndex [::Word]

Word, Top

Set the end index of a text range.

SetRangeEndIndex rangeId index

###### Parameters

rangeId | Identifier of the text range.
index | Index for the range end.

###### Return value

Returns no value.

###### Description

Set the end index of a text range.

Index is either an integer value or string "end" to use the end of the document.

See also: SetRangeStartIndex GetRangeEndIndex

#### SetRangeFontBackgroundColor [::Word]

Word, Top

Set the background color of a text range.

SetRangeFontBackgroundColor rangeId args

###### Parameters

rangeId | Identifier of the text range.
args | Text color.

###### Return value

Returns no value.

###### Description

Set the background color of a text range.

Color value may be specified in a format acceptable by procedure ::Cawt::GetColor, i.e. color name, hexadecimal string, Office color number or a list of 3 integer RGB values.

See also: SetRangeBackgroundColor SetRangeHighlightColorByEnum ::Cawt::GetColor

#### SetRangeFontBold [::Word]

Word, Top

Toggle the bold font style of a text range.

SetRangeFontBold rangeId onOff

###### Parameters

rangeId | Identifier of the text range.
onOff | (optional, default true) true: Set bold style on. false: Set bold style off.

###### Return value

Returns no value.

###### Description

Toggle the bold font style of a text range.

See also: SetRangeFontName SetRangeFontSize SetRangeFontItalic SetRangeFontUnderline

#### SetRangeFontItalic [::Word]

Word, Top

Toggle the italic font style of a text range.

SetRangeFontItalic rangeId onOff

###### Parameters

rangeId | Identifier of the text range.
onOff | (optional, default true) true: Set italic style on. false: Set italic style off.

###### Return value

Returns no value.

###### Description

Toggle the italic font style of a text range.

See also: SetRangeFontName SetRangeFontSize SetRangeFontBold SetRangeFontUnderline

#### SetRangeFontName [::Word]

Word, Top

Set the font name of a text range.

SetRangeFontName rangeId fontName

###### Parameters

rangeId | Identifier of the text range.
fontName | Font name.

###### Return value

Returns no value.

###### Description

Set the font name of a text range.

See also: SetRangeFontSize SetRangeFontBold SetRangeFontItalic SetRangeFontUnderline

#### SetRangeFontSize [::Word]

Word, Top

Set the font size of a text range.

SetRangeFontSize rangeId fontSize

###### Parameters

rangeId | Identifier of the text range.
fontSize | Font size.

###### Return value

Returns no value.

###### Description

Set the font size of a text range.

The size value may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: SetRangeFontName SetRangeFontBold SetRangeFontItalic SetRangeFontUnderline ::Cawt::ValueToPoints

#### SetRangeFontUnderline [::Word]

Word, Top

Toggle the underline font style of a text range.

SetRangeFontUnderline rangeId onOff color

###### Parameters

rangeId | Identifier of the text range.
onOff | (optional, default true) true: Set underline style on. false: Set underline style off.
color | (optional, default wdColorAutomatic) Value of enumeration type WdColor (see wordConst.tcl)

###### Return value

Returns no value.

###### Description

Toggle the underline font style of a text range.

See also: SetRangeFontName SetRangeFontSize SetRangeFontBold SetRangeFontItalic

#### SetRangeHighlightColorByEnum [::Word]

Word, Top

Set the highlight color of a text range.

SetRangeHighlightColorByEnum rangeId colorEnum

###### Parameters

rangeId | Identifier of the text range.
colorEnum | Value of enumeration type WdColorIndex (see wordConst.tcl).

###### Return value

Returns no value.

###### Description

Set the highlight color of a text range.

See also: SetRangeBackgroundColorByEnum

#### SetRangeHorizontalAlignment [::Word]

Word, Top

Set the horizontal alignment of a text range.

SetRangeHorizontalAlignment rangeId align

###### Parameters

rangeId | Identifier of the text range.
align | Value of enumeration type WdParagraphAlignment (see wordConst.tcl) or any of the following strings: left, right, center.

###### Return value

Returns no value.

###### Description

Set the horizontal alignment of a text range.

See also: SetCellVerticalAlignment SetRangeHighlightColorByEnum

#### SetRangeMergeCells [::Word]

Word, Top

Merge a range of cells.

SetRangeMergeCells rangeId

###### Parameters

rangeId | Identifier of the cell range.

###### Return value

Returns no value.

###### Description

Merge a range of cells.

See also: SetRangeHorizontalAlignment SelectRange

#### SetRangeStartIndex [::Word]

Word, Top

Set the start index of a text range.

SetRangeStartIndex rangeId index

###### Parameters

rangeId | Identifier of the text range.
index | Index for the range start.

###### Return value

Returns no value.

###### Description

Set the start index of a text range.

Index is either an integer value or string "begin" to use the start of the document.

See also: SetRangeEndIndex GetRangeStartIndex

#### SetRangeStyle [::Word]

Word, Top

Set the style of a text range.

SetRangeStyle rangeId style

###### Parameters

rangeId | Identifier of the text range.
style | Value of enumeration type WdBuiltinStyle (see wordConst.tcl). Often used values: Word::wdStyleHeading1, Word::wdStyleNormal

###### Return value

Returns no value.

###### Description

Set the style of a text range.

See also: SetRangeFontSize SetRangeFontName

#### SetRowHeight [::Word]

Word, Top

Set the height of a table row.

SetRowHeight tableId row height

###### Parameters

tableId | Identifier of the Word table.
row | Row number. Row numbering starts with 1.
height | (optional, default 0) A positive value specifies the row's height. A value of zero specifies that the rows's height fits automatically the height of all elements in the row.

###### Return value

Returns no value.

###### Description

Set the height of a table row.

The height value may be specified in a format acceptable by procedure Cawt::ValueToPoints, i.e. centimeters, inches or points.

See also: SetRowValues ::Cawt::ValueToPoints

#### SetRowValues [::Word]

Word, Top

Insert row values from a Tcl list.

SetRowValues tableId row valList startCol numVals

###### Parameters

tableId | Identifier of the Word table.
row | Row number. Row numbering starts with 1.
valList | List of values to be inserted.
startCol | (optional, default 1) Column number of insertion start. Column numbering starts with 1.
numVals | (optional, default 0) Negative or zero: All list values are inserted. Positive: numVals columns are filled with the list values (starting at list index 0).

###### Return value

Returns no value. If valList is an empty list, an error is thrown.

###### Description

Insert row values from a Tcl list.

See also: GetRowValues SetColumnValues SetCellValue

#### SetTableBorderLineStyle [::Word]

Word, Top

Set the border line styles of a Word table.

SetTableBorderLineStyle tableId outsideLineStyle insideLineStyle

###### Parameters

tableId | Identifier of the Word table.
outsideLineStyle | (optional, default wdLineStyleSingle) Outside border style.
insideLineStyle | (optional, default wdLineStyleSingle) Inside border style.

###### Return value

Returns no value.

###### Description

Set the border line styles of a Word table.

The values of "outsideLineStyle" and "insideLineStyle" must be of enumeration type WdLineStyle (see WordConst.tcl).

See also: AddTable SetTableBorderLineWidth

#### SetTableBorderLineWidth [::Word]

Word, Top

Set the border line widths of a Word table.

SetTableBorderLineWidth tableId outsideLineWidth insideLineWidth

###### Parameters

tableId | Identifier of the Word table.
outsideLineWidth | (optional, default wdLineWidth050pt) Outside border line width.
insideLineWidth | (optional, default wdLineWidth050pt) Inside border line width.

###### Return value

Returns no value.

###### Description

Set the border line widths of a Word table.

The values of "outsideLineWidth" and "insideLineWidth" must be of enumeration type WdLineWidth (see WordConst.tcl).

See also: AddTable SetTableBorderLineStyle

#### SetTableName [::Word]

Word, Top

Set the name of a table.

SetTableName tableId name

###### Parameters

tableId | Identifier of the Word table.
name | Name of the table.

###### Return value

Returns no value.

###### Description

Set the name of a table.

Table names are supported since Word 2010. If your Word version is older, an error is thrown.

See also: GetTableName GetNumTables AddTable

#### ShowAlerts [::Word]

Word, Top

Toggle the display of Word application alerts.

ShowAlerts appId onOff

###### Parameters

appId | The application identifier.
onOff | Switch the alerts on or off.

###### Return value

Returns no value.

###### Description

Toggle the display of Word application alerts.

#### ToggleSpellCheck [::Word]

Word, Top

Toggle checking of grammatical and spelling errors.

ToggleSpellCheck appId onOff

###### Parameters

appId | Identifier of the Word instance.
onOff |

###### Return value

Returns no value.

###### Description

Toggle checking of grammatical and spelling errors.

See also: Open

#### TrimString [::Word]

Word, Top

Trim a string.

TrimString str

###### Parameters

str | String to be trimmed.

###### Return value

Returns the trimmed string.

###### Description

Trim a string.

The string is trimmed from the left and right side. Trimmed characters are whitespaces. Additionally the following control characters are converted: 0xD to \n, 0x7 to space.

#### UpdateFields [::Word]

Word, Top

Update all fields as well as tables of content and figures of a document.

UpdateFields docId

###### Parameters

docId | Identifier of the document.

###### Return value

Returns no value.

###### Description

Update all fields as well as tables of content and figures of a document.

See also: SaveAs

#### Visible [::Word]

Word, Top

Toggle the visibility of a Word application window.

Visible appId visible

###### Parameters

appId | Identifier of the Word instance.
visible | true: Show the application window. false: Hide the application window.

###### Return value

Returns no value.

###### Description

Toggle the visibility of a Word application window.

See also: Open OpenNew IsVisible

# CAWT Reference 2.4.3

# ::Cawt

## Introduction

## Commands

#### CentiMetersToPointsConvert centimeter value into points.

#### CheckBooleanCheck, if two boolean values are identical.

#### CheckComObjectsCheck, if the number of COM objects fits expected value.

#### CheckListCheck, if two lists are identical.

#### CheckMatrixCheck, if two matrices are identical.

#### CheckNumberCheck, if two numerical values are identical.

#### CheckStringCheck, if two string values are identical.

#### ClipboardToImgCopy the clipboard content into a photo image.

#### ConcatFiles

#### CountWordsCount words contained in a string.

#### DestroyDestroy one or all COM objects.

#### GetColorConvert a color representation into an Office color number.

#### GetColorNamesGet all supported Tcl color names.

#### GetComObjectsGet the COM objects currently in use as a list.

#### GetDotsPerInchGet the dots-per-inch value used for conversions.

#### GetNumComObjectsGet the number of COM objects currently in use.

#### GetOrCreateAppUse or create an instance of an application.

#### GetPkgVersionGet the version of a Cawt sub-package.

#### GetProgramByExtensionGet path to program for a given file extension.

#### HavePkgCheck, if a Cawt sub-package is available.

#### ImgToClipboardCopy a photo image into the clipboard.

#### InchesToPointsConvert inch value into points.

#### IsComObjectCheck, if a COM object is valid.

#### IsHexColorCheck, if specified color is a valid Tcl hexadecimal color string.

#### IsNameColorCheck, if specified color is a valid Tcl color name.

#### IsoDateToOutlookDateReturn ISO date string as Outlook date.

#### IsoDateToSecondsReturn ISO date string as seconds.

#### IsoDateToXmlDateReturn ISO date string as XML date string.

#### IsOfficeColorCheck, if specified color is a valid Office color number.

#### IsRgbColorCheck, if specified color is a valid RGB representation.

#### IsUnicodeFileCheck, if a file is encode in Unicode.

#### IsValidIdObsolete: Replaced with IsComObject in version 2.0.0

#### KillAppKill all running instances of an application.

#### OfficeColorToRgbConvert an Office color number into a RGB color list.

#### OutlookDateToIsoDateReturn Outlook date as ISO date string.

#### OutlookDateToSecondsReturn Outlook date as seconds.

#### PointsToCentiMetersConvert value in points into centimeters.

#### PointsToInchesConvert value in points into inches.

#### PopComObjectsPop last entry from COM objects stack.

#### PrintNumComObjectsPrint the number of currently available COM objects to stdout.

#### PushComObjectsPush current list of COM objects onto a stack.

#### RgbToOfficeColorConvert a RGB color into an Office color number.

#### SecondsToIsoDateReturn date in seconds as ISO date string.

#### SecondsToOutlookDateReturn date in seconds as Outlook date.

#### SecondsToXmlDateReturn date in seconds as XML date string.

#### SetDotsPerInchSet the dots-per-inch value used for conversions.

#### SplitFile

#### TclBoolCast a value to a boolean.

#### TclIntCast a value to an integer with boolean range.

#### TclStringCast a value to a string.

#### ValueToPointsConvert a value into points.

#### XmlDateToIsoDateReturn XML date string as ISO date string.

#### XmlDateToSecondsReturn XML date string as seconds.

# ::Earth

## Introduction

## Commands

#### IsInitializedCheck, if a GoogleEarth instance is initialized.

#### OpenOpen a GoogleEarth instance. Use an already running instance, if available.

#### OpenNewOpen a new GoogleEarth instance.

#### QuitQuit a GoogleEarth instance.

#### SaveImageSave a grey-scale image of the current view.

#### SetCameraSet camera position and orientation.

# ::Excel

## Introduction

## Commands

#### AddColumnChartSimpleAdd a clustered column chart to a worksheet. Simple case.

#### AddLineChartAdd a line chart to a worksheet. Generic case.

#### AddLineChartSimpleAdd a line chart to a worksheet. Simple case.

#### AddPointChartSimpleAdd a point chart to a worksheet. Simple case.

#### AddRadarChartSimpleAdd a radar chart to a worksheet. Simple case.

#### AddSeriesTrendLineAdd a trend line to a series.

#### AddWorkbookAdd a new workbook with one worksheet.

#### AddWorksheetAdd a new worksheet to the end of a workbook.

#### ArrangeWindowsArrange the windows of an Excel application.

#### ChartObjToClipboardCopy a chart object to the clipboard.

#### ChartToClipboardObsolete: Replaced with ChartObjToClipboard in version 1.0.1

#### ClipboardToMatrixReturn the matrix values contained in the clipboard.

#### ClipboardToWorksheetInsert the matrix values contained in the clipboard into a worksheet.

#### CloseClose a workbook without saving changes.

#### ColumnCharToIntReturn an Excel column string as a column number.

#### ColumnIntToCharReturn a column number as an Excel column string.

#### CopyColumnCopy the contents of a column into another column.

#### CopyRangeCopy the contents of a cell range into another cell range.

#### CopyWorksheetCopy the contents of a worksheet into another worksheet.

#### CopyWorksheetAfterCopy the contents of a worksheet after another worksheet.

#### CopyWorksheetBeforeCopy the contents of a worksheet before another worksheet.

#### CreateChartCreate a new empty chart in a worksheet.

#### CreateRangeStringCreate a range string in A1 notation.

#### CsvRowToListReturn a CSV encoded row as a list of column values.

#### CsvStringToMatrixReturn a matrix from a CSV encoded table string.

#### DeleteColumnDelete a column.

#### DeleteRowDelete a row.

#### DeleteWorksheetDelete a worksheet.

#### DeleteWorksheetByIndexDelete a worksheet identified by its index.

#### DiffExcelFilesCompare two Excel files visually.

#### DuplicateColumnDuplicate a column.

#### DuplicateRowDuplicate a row.

#### ExcelFileToHtmlFileConvert an Excel file to a HTML table file.

#### ExcelFileToMatlabFileConvert an Excel file to a Matlab table file.

#### ExcelFileToMediaWikiFileConvert an Excel file to a MediaWiki table file.

#### ExcelFileToRawImageFileConvert an Excel file to a raw photo image file.

#### ExcelFileToWikitFileConvert an Excel file to a Wikit table file.

#### FormatHeaderRowFormat a row as a header row.

#### FreezePanesFreeze a range in a worksheet identified by its row/column index.

#### GetActiveWorkbookReturn the active workbook of an application.

#### GetCellCommentReturn the comment text of a cell.

#### GetCellIdByIndexReturn a cell of a worksheet.

#### GetCellRangeReturn a numeric cell range as an Excel range string in A1 notation.

#### GetCellsIdReturn the cells identifier of a worksheet.

#### GetCellValueReturn the value of a cell.

#### GetChartNumSeriesReturn the number of series of a chart.

#### GetChartSeriesGet a specific series of a chart.

#### GetColumnNumberReturn an Excel column string or number as a column number.

#### GetColumnRangeReturn a numeric column range as an Excel range string.

#### GetColumnValuesReturn column values as a Tcl list.

#### GetCsvSeparatorCharReturn the column separator character.

#### GetCurrencyFormatReturn an Excel number format string for currencies.

#### GetDecimalSeparatorReturn the decimal separator used by Excel.

#### GetEnumGet numeric value of an enumeration.

#### GetEnumNameGet name of a given enumeration type and numeric value.

#### GetEnumNamesGet names of a given enumeration type.

#### GetEnumTypesGet available enumeration types.

#### GetEnumValGet numeric value of an enumeration name.

#### GetExtStringReturn the default extension of an Excel file.

#### GetFirstUsedColumnReturn the index of the first used column of a worksheet.

#### GetFirstUsedRowReturn the index of the first used row of a worksheet.

#### GetFloatSeparatorObsolete: Replaced with GetDecimalSeparator in version 2.1.0

#### GetHiddenColumnsReturn the hidden columns of a worksheet.

#### GetHiddenRowsReturn the hidden rows of a worksheet.

#### GetLangNumberFormatObsolete: Replaced with GetNumberFormat in version 2.1.0

#### GetLastUsedColumnReturn the index of the last used column of a worksheet.

#### GetLastUsedRowReturn the index of the last used row of a worksheet.

#### GetMatrixValuesReturn worksheet table values as a matrix.

#### GetMaxColumnsReturn the maximum number of columns of an Excel table.

#### GetMaxRowsReturn the maximum number of rows of an Excel table.

#### GetNamedRangeGet the identifier of a named range.

#### GetNamedRangeNamesGet the names of named ranges.

#### GetNumberFormatReturn an Excel number format string.

#### GetNumColumnsReturn the number of columns of a cell range.

#### GetNumRowsReturn the number of rows of a cell range.

#### GetNumUsedColumnsReturn the number of used columns of a worksheet.

#### GetNumUsedRowsReturn the number of used rows of a worksheet.

#### GetNumWorksheetsReturn the number of worksheets in a workbook.

#### GetRangeAsIndexGet address of a cell range as list of row/column indices.

#### GetRangeAsStringGet address of a cell range as Excel range string in A1 notation.

#### GetRangeCharactersReturn characters of a cell range.

#### GetRangeFillColorGet the fill color of a cell range.

#### GetRangeFontBoldGet the bold font style of a cell range.

#### GetRangeFontItalicGet the italic font style of a cell range.

#### GetRangeFontNameGet the font name of a cell or character range.

#### GetRangeFontSizeGet the font size of a cell range.

#### GetRangeFontSubscriptGet the subscript font style of a cell or character range.

#### GetRangeFontSuperscriptGet the superscript font style of a cell or character range.

#### GetRangeFontUnderlineGet the underline font style of a cell range.

#### GetRangeFormatGet the number format of a cell range.

#### GetRangeHorizontalAlignmentGet the horizontal alignment of a cell range.

#### GetRangeTextColorGet the text color of a cell range.

#### GetRangeValuesReturn range values as a matrix.

#### GetRangeVerticalAlignmentGet the vertical alignment of a cell range.

#### GetRangeWrapTextGet the wrap text mode of a cell range.

#### GetRowValuesReturn row values as a Tcl list.

#### GetTablelistHeaderReturn the header line of a tablelist as a list.

#### GetTablelistValuesReturn the values of a tablelist as a matrix.

#### GetThousandsSeparatorReturn the thousands separator used by Excel.

#### GetVersionReturn the version of an Excel application.

#### GetWorkbookIdByNameFind an open workbook by its name.

#### GetWorkbookNameReturn the name of a workbook.

#### GetWorksheetAsMatrixReturn worksheet table as a matrix.

#### GetWorksheetIdByIndexFind a worksheet by its index.

#### GetWorksheetIdByNameFind a worksheet by its name.

#### GetWorksheetIndexByNameFind a worksheet index by its name.

#### GetWorksheetNameReturn the name of a worksheet.

#### HideColumnHide or unhide a column.

#### HideRowHide or unhide a row.

#### ImgToWorksheetPut a photo image into a worksheet.

#### ImportImport data from an external data source.

#### InsertColumnInsert a new empty column.

#### InsertImageInsert an image into a worksheet.

#### InsertRowInsert a new empty row.

#### IsWorkbookIdCheck, if Excel object is a workbook identifier.

#### IsWorkbookOpenCheck, if a workbook is open.

#### IsWorkbookProtectedCheck, if a workbook is protected.

#### IsWorksheetEmptyCheck, if a worksheet is empty.

#### IsWorksheetProtectedCheck, if a worksheet is content protected.

#### IsWorksheetVisibleCheck, if a worksheet is visible.

#### ListToCsvRowReturn a list of column values as a CSV encoded row string.

#### MatlabFileToExcelFileConvert a Matlab table file to an Excel file.

#### MatlabFileToWorksheetInsert the data values of a Matlab file into a worksheet.

#### MatrixToClipboardCopy a matrix into the clipboard.

#### MatrixToCsvStringReturn a CSV encoded table string from a matrix list.

#### MediaWikiFileToExcelFileConvert a MediaWiki table file to an Excel file.

#### MediaWikiFileToWorksheetInsert the values of a MediaWiki table file into a worksheet.

#### OpenOpen an Excel instance. Use an already running instance, if available.

#### OpenNewOpen a new Excel instance.

#### OpenWorkbookOpen a workbook, i.e. load an Excel file.

#### PlaceChartPlace an existing chart into a worksheet.

#### QuitQuit an Excel instance.

#### RawImageFileToExcelFileConvert a raw photo image file to an Excel file.

#### RawImageFileToWorksheetInsert the pixel values of a raw photo image into a worksheet.

#### ReadCsvFileRead a CSV table file into a matrix.

#### ReadMatlabFileRead a Matlab file into a matrix.

#### ReadMatlabHeaderRead the header of a Matlab file.

#### ReadMediaWikiFileRead a MediaWiki table file into a matrix.

#### ReadRawImageFileRead a raw photo image into a matrix.

#### ReadRawImageHeaderRead the header of a raw photo image.

#### ReadWikitFileRead a Wikit table file into a matrix.

#### ResizeChartObjSet the position and size of a chart object.

#### SaveAsSave a workbook to an Excel file.

#### SaveAsCsvSave a worksheet to file in CSV format.

#### SaveChartAsImageObsolete: Replaced with SaveChartObjAsImage in version 1.0.1

#### SaveChartObjAsImageSave a chart as an image in a file.

#### ScaleImageScale an image.

#### ScreenUpdateToggle the screen updating of an Excel application window.

#### SearchFind a string in a worksheet cell range.

#### SelectAllSelect all cells of a worksheet.

#### SelectCellByIndexSelect a cell by its row/column index.

#### SelectRangeByIndexSelect a range by specifying a numeric cell range.

#### SelectRangeByStringSelect a range by specifying an Excel range string in A1 notation.

#### SetCellValueSet the value of a cell.

#### SetChartMaxScaleSet the maximum scale of an axis of a chart.

#### SetChartMinScaleSet the minimum scale of an axis of a chart.

#### SetChartObjPositionSet the position of a chart object.

#### SetChartObjSizeSet the size of a chart object.

#### SetChartScaleSet the minimum and maximum scale of both axes of a chart.

#### SetChartSizeObsolete: Replaced with SetChartObjSize in version 1.0.1

#### SetChartSourceByIndexSet the cell range for the source of a chart.

#### SetChartTicksSet the tick spacing of an axis of a chart.

#### SetChartTitleSet the title of a chart.

#### SetColumnsWidthSet the width of a range of columns.

#### SetColumnValuesInsert column values from a Tcl list.

#### SetColumnWidthSet the width of a column.

#### SetCommentDisplayModeSet the global display mode of comments.

#### SetCommentSizeSet the shape size of a comment.

#### SetCsvSeparatorCharSet the column separator character.

#### SetHeaderRowInsert row values from a Tcl list and format as a header row.

#### SetHyperlinkInsert a hyperlink into a cell.

#### SetHyperlinkToCellInsert a hyperlink to a cell into another cell.

#### SetHyperlinkToFileInsert a hyperlink to a file into a cell.

#### SetLinkToCellInsert an internal link to a cell into another cell.

#### SetMatrixValuesInsert matrix values into a worksheet.

#### SetNamedRangeSet the name of a cell range.

#### SetRangeBorderSet the attributes of one border of a cell range.

#### SetRangeBordersSet the attributes of all borders of a cell range.

#### SetRangeCommentSet the comment text of a cell range.

#### SetRangeFillColorSet the fill color of a cell range.

#### SetRangeFontBoldSet the bold font style of a cell range.

#### SetRangeFontItalicSet the italic font style of a cell range.

#### SetRangeFontNameSet the font name of a cell or character range.

#### SetRangeFontSizeSet the font size of a cell range.

#### SetRangeFontSubscriptSet the subscript font style of a cell or character range.

#### SetRangeFontSuperscriptSet the superscript font style of a cell or character range.

#### SetRangeFontUnderlineSet the underline font style of a cell range.

#### SetRangeFormatSet the number format of a cell range.

#### SetRangeHorizontalAlignmentSet the horizontal alignment of a cell range.

#### SetRangeMergeCellsMerge/Unmerge a range of cells.

#### SetRangeTextColorSet the text color of a cell range.

#### SetRangeTooltipSet a selection based tooltip for a cell range.

#### SetRangeValuesSet range values from a matrix.

#### SetRangeVerticalAlignmentSet the vertical alignment of a cell range.

#### SetRangeWrapTextSet the text wrapping mode of a cell range.

#### SetRowHeightSet the height of a row.

#### SetRowsHeightSet the height of a range of rows.

#### SetRowValuesInsert row values from a Tcl list.

#### SetSeriesLineWidthSet the line width of a series.

#### SetTablelistHeaderInsert header values into a tablelist.

#### SetTablelistValuesInsert matrix values into a tablelist.

#### SetWindowStateSet the window state of an Excel application.

#### SetWorksheetFitToPagesAdjust a worksheet to fit onto given number of pages.

#### SetWorksheetFooterSet the texts of the footer of a worksheet.

#### SetWorksheetHeaderSet the texts of the header of a worksheet.

#### SetWorksheetMarginsSet the margins of a worksheet.

#### SetWorksheetNameSet the name of a worksheet.

#### SetWorksheetOrientationSet the orientation of a worksheet.

#### SetWorksheetPaperSizeSet the paper size of a worksheet.

#### SetWorksheetPrintOptionsSet printing options of a worksheet.

#### SetWorksheetTabColorSet the color of the tab of a worksheet.

#### SetWorksheetZoomSet the zoom factor for printing of a worksheet.

#### ShowAlertsToggle the display of Excel application alerts.

#### ShowCellByIndexShow a cell identified by its row/column index.

#### ShowWorksheetShow a worksheet.

#### TablelistToWorksheetInsert the values of a tablelist into a worksheet.

#### ToggleAutoFilterToggle the AutoFilter switch of a cell range.

#### UnhideWorksheetUnhide a worksheet, if it is hidden.

#### UseImgTransparencyToggle usage of transparency channel of an image.

#### VisibleSet or query the visibility of an Excel application window.

#### WikitFileToExcelFileConvert a Wikit table file to an Excel file.

#### WikitFileToWorksheetInsert the values of a Wikit table file into a worksheet.

#### WordTableToWorksheetInsert the values of a Word table into a worksheet.

#### WorksheetToClipboardCopy worksheet data into the clipboard.

#### WorksheetToHtmlFileWrite the values of a worksheet into a HTML table file.

#### WorksheetToImgPut worksheet background colors into a photo image.

#### WorksheetToMatlabFileInsert the values of a worksheet into a Matlab file.

#### WorksheetToMediaWikiFileInsert the values of a worksheet into a MediaWiki table file.

#### WorksheetToRawImageFileInsert the values of a worksheet into a raw photo image file.

#### WorksheetToTablelistInsert the values of a worksheet into a tablelist.

#### WorksheetToWikitFileInsert the values of a worksheet into a Wikit table file.

#### WorksheetToWordTableInsert the values of a worksheet into a Word table.

#### WriteCsvFileWrite the values of a matrix into a CSV file.

#### WriteHtmlFileWrite the values of a matrix into a Html table file.

#### WriteMatlabFileWrite the values of a matrix into a Matlab file.

#### WriteMediaWikiFileWrite the values of a matrix into a MediaWiki table file.

#### WriteRawImageFileWrite the values of a matrix into a raw photo image file.

#### WriteWikitFileWrite the values of a matrix into a Wikit table file.

# ::Explorer

## Introduction

## Commands

#### FullScreenToggle the fullscreen mode of an Internet Explorer application window.

#### GoGo to a specific page.

#### IsBusyCheck, if an Internet Explorer instance is busy.

#### NavigateNavigate to a URL or local file.

#### OpenOpen an Internet Explorer instance. Use an already running instance, if available. Use an already running Internet Explorer, if available.

#### OpenNewOpen a new Internet Explorer instance.

#### QuitQuit an Internet Explorer instance.

#### VisibleToggle the visibility of an Internet Explorer application window.

# ::Matlab

## Introduction

## Commands

#### ExecCmdExecute a Matlab command.

#### OpenOpen a Matlab instance. Use an already running instance, if available.

#### OpenNewOpen a new Matlab instance.

#### QuitQuit a Matlab instance.

#### VisibleToggle the visibility of a Matlab application window.

# ::Ocr

## Introduction

## Commands

#### CloseClose an OCR document instance.

#### GetFullTextReturn the recognized text of an OCR layout.

#### GetNumImagesReturn the number of images of an OCR document.

#### GetNumWordsReturn the number of words identified in an OCR document.

#### GetWordReturn the text of a recognized word.

#### GetWordStatsReturn statistics of a recognized word.

#### OpenOpen an OCR document instance.

#### OpenDocumentOpen an image file for OCR scanning.

#### ScanScan an image.

# ::Office

## Commands

#### ColorToRgbObsolete: Replaced with ::Cawt::OfficeColorToRgb in version 2.2.0

#### GetActivePrinterGet the name of the active printer.

#### GetApplicationIdGet the application identifier of an Office object.

#### GetApplicationNameGet the name of an Office application.

#### GetApplicationVersionGet the version number of an Office application.

#### GetDocumentPropertiesGet document property names as a list.

#### GetDocumentPropertyGet the value of a document property.

#### GetEnumGet numeric value of an enumeration.

#### GetEnumNameGet name of a given enumeration type and numeric value.

#### GetEnumNamesGet names of a given enumeration type.

#### GetEnumTypesGet available enumeration types.

#### GetEnumValGet numeric value of an enumeration name.

#### GetInstallationPathGet the Office installation pathname.

#### GetOfficeTypeGet the Office type of a file.

#### GetStartupPathGet the Office startup pathname.

#### GetTemplatesPathGet the Office templates pathname.

#### GetUserLibraryPathGet the Office user library pathname.

#### GetUserNameGet the name of the Office application user.

#### GetUserPathGet the Office user folder's pathname.

#### IsApplicationIdCheck, if Office object is an application identifier.

#### RgbToColorObsolete: Replaced with ::Cawt::RgbToOfficeColor in version 2.2.0

#### SetDocumentPropertySet the value of a document property.

#### SetPrinterCommunicationEnable or disable printer communication.

#### ShowAlertsObsolete: Replaced with module specific procedures in version 2.4.3

# ::OneNote

## Introduction

## Commands

#### FindNodeByNameGet a specific node by name.

#### FindNotebookGet a specific notebook by name.

#### FindPageGet a specific page by name.

#### FindSectionGet a specific section by name.

#### GetApplicationIdGet the application identifier of a OneNote object.

#### GetDomIdGet the DOM identifier of a OneNote object.

#### GetDomRootGet the DOM root of a OneNote object.

#### GetEnumGet numeric value of an enumeration.

#### GetEnumNamesGet names of a given enumeration type.

#### GetEnumTypesGet available enumeration types.

#### GetEnumValGet numeric value of an enumeration name.

#### GetExtStringReturn the default extension of a OneNote file.

#### GetLastModifiedGet nodes with specific modification date.

#### GetNodeAttributeGet attribute value of a DOM node.

#### GetNodeHyperLinkGet hyperlink to OneNote node.

#### GetNodeNameGet value of node attribute "name".

#### GetNodesByTypeGet nodes of specific type.

#### GetNodeTypeGet type of a DOM node.

#### GetNotebooksGet the notebooks of a OneNote object.

#### GetPageContentGet page content as XML.

#### GetPagesGet the pages of a OneNote section.

#### GetSectionsGet the sections of a OneNote notebook.

#### GetVersionReturn the version of a OneNote application.

#### IsNodeTypeCheck, if node is of specific type.

#### OpenOpen a OneNote instance.

#### PrintPagePrint page content as XML to standard output.

#### QuitQuit a OneNote instance.

# ::Outlook

## Introduction

## Commands

#### AddAppointmentCreate a new appointment in an Outlook calendar.

#### AddCalendarAdd a new calendar.

#### AddCategoryAdd a new category to the Outlook categories.

#### AddHolidayAppointmentCreate a new appointment in an Outlook calendar.

#### ApplyHolidayFileRead an Outlook holiday file and insert appointments.

#### CreateHtmlMailCreate a new Outlook HTML mail.

#### CreateMailCreate a new Outlook text mail.

#### DeleteAppointmentByIndexDelete an appointment of an Outlook calendar by its index.

#### DeleteCalendarDelete an Outlook calendar.

#### DeleteCategoryDelete an Outlook category.

#### GetAppointmentByIndexGet an appointment of an Outlook calendar by its index.

#### GetAppointmentPropertiesGet properties of an appointment.

#### GetCalendarIdGet a calendar by its name.

#### GetCalendarNamesGet a list of calendar names.

#### GetCategoryColorConvert a category color enumeration or name into a hexadecimal Tcl color string representation.

#### GetCategoryColorEnumConvert a category color enumeration or name into a color enumeration.

#### GetCategoryColorNameConvert a category color enumeration into a category color name.

#### GetCategoryColorNamesGet all category color names.

#### GetCategoryIdGet a category by its index or name.

#### GetCategoryNamesGet a list of category names.

#### GetEnumGet numeric value of an enumeration.

#### GetEnumNameGet name of a given enumeration type and numeric value.

#### GetEnumNamesGet names of a given enumeration type.

#### GetEnumTypesGet available enumeration types.

#### GetEnumValGet numeric value of an enumeration name.

#### GetFoldersRecursive

#### GetMailIdsGet a list of mail identifiers.

#### GetMailSubjectsGet a list of mail subjects.

#### GetNumAppointmentsGet the number of appointments in an Outlook calendar.

#### GetNumCalendarsGet the number of Outlook calendars.

#### GetNumCategoriesGet the number of Outlook categories.

#### GetVersionGet the version of an Outlook application.

#### HaveCalendarCheck, if a calendar already exists.

#### HaveCategoryCheck, if a category already exists.

#### OpenOpen an Outlook instance.

#### OpenNewObsolete: Replaced with Open in version 2.4.1

#### QuitQuit an Outlook instance.

#### ReadHolidayFileRead an Outlook holiday file.

#### SendMailSend an Outlook mail.

# ::Ppt

## Introduction

## Commands

#### AddPresAdd a new empty presentation.

#### AddShapeAdd a new shape to a slide.

#### AddSlideAdd a new slide to a presentation.

#### AddTextboxAdd a text box into a slide.

#### AddTextboxTextAdd a text string to a text box.

#### CloseClose a presentation without saving changes.

#### CloseAllClose all presentations of a PowerPoint instance.

#### ConfigureConnectorConfigure a connector.

#### ConfigureShapeConfigure a shape.

#### ConnectShapesAdd a new connector connecting two shapes.

#### CopySlideMake a copy of a slide.

#### ExitSlideShowExit specified slide show.

#### ExportPptFileExport a PowerPoint file to an image sequence.

#### ExportSlideExport a slide as an image.

#### ExportSlidesExport a range of slides as image files.

#### GetActivePresReturn the active presentation of an application.

#### GetCommentKeyTopPositionReturn the top position of a comment with specific key.

#### GetCommentKeyValueReturn the value of a key stored in a comment.

#### GetCommentsGet the comment texts of a slide as a Tcl list.

#### GetCustomLayoutIdGet a custom layout by its index or name.

#### GetCustomLayoutNameReturn the name of a custom layout.

#### GetEnumGet numeric value of an enumeration.

#### GetEnumNameGet name of a given enumeration type and numeric value.

#### GetEnumNamesGet names of a given enumeration type.

#### GetEnumTypesGet available enumeration types.

#### GetEnumValGet numeric value of an enumeration name.

#### GetExtStringReturn the default extension of a PowerPoint file.

#### GetNumCommentsReturn the number of comments of a slide.

#### GetNumCustomLayoutsReturn the number of custom layouts of a presentation.

#### GetNumShapesReturn the number of shapes of a slide.

#### GetNumSitesReturn the number of sites of a shape.

#### GetNumSlidesReturn the number of slides of a presentation.

#### GetNumSlideShowsReturn the number of slide shows of a presentation.

#### GetPresImagesGet the images of a presentation.

#### GetPresVideosGet the videos of a presentation.

#### GetShapeIdGet shape identifier from shape index.

#### GetShapeMediaTypeReturn the media type of a shape.

#### GetShapeNameReturn the name of a shape.

#### GetShapeTypeReturn the type of a shape.

#### GetSlideIdGet slide identifier from slide index.

#### GetSlideIndexReturn the index of a slide.

#### GetTemplateExtStringReturn the default extension of a PowerPoint template file.

#### GetVersionReturn the version of a PowerPoint application.

#### GetViewTypeReturn the view type of a presentation.

#### InsertImageInsert an image into a slide.

#### InsertVideoInsert a video into a slide.

#### MoveSlideMove a slide to another position.

#### OpenOpen a PowerPoint instance. Use an already running instance, if available.

#### OpenNewOpen a new PowerPoint instance.

#### OpenPresOpen a presentation, i.e. load a PowerPoint file.

#### QuitQuit a PowerPoint instance.

#### SaveAsSave a presentation to a PowerPoint file.

#### SetHyperlinkToSlideCreate a hyperlink from a shape to a slide.

#### SetMediaPlaySettingsSet the play settings of a media (audio or video).

#### SetPresPageSetupSet the page size of a presentation.

#### SetShapeNameSet the name of a shape.

#### SetTextboxFontSizeSet the font size of the text in a text box.

#### SetViewTypeSet the view type of a presentation.

#### ShowAlertsToggle the display of PowerPoint application alerts.

#### ShowSlideShow a specific slide.

#### SlideShowFirstGo to first slide in slide show.

#### SlideShowLastGo to last slide in slide show.

#### SlideShowNextGo to next slide in slide show.

#### SlideShowPrevGo to previous slide in slide show.

#### UseSlideShowUse specified slide show.

#### VisibleToggle the visibility of a PowerPoint application window.

# ::Reader

## Introduction

## Commands

#### OpenOpen an Acrobat Reader instance. Use an already running instance, if available.

#### OpenNewOpen a new Acrobat Reader instance.

#### QuitQuit all Acrobat Reader instances.

#### SetReaderProgSet the path to Acrobat Reader program.

# ::Word

## Introduction

## Commands

#### AddBookmarkAdd a bookmark to a text range.

#### AddContentControlAdd a content control to a text range.

#### AddDocumentAdd a new empty document to a Word instance.

#### AddImageTableAdd a new table and fill the cells with images.

#### AddPageBreakAdd a page break to a text range.

#### AddParagraphAdd a new paragraph to a document.

#### AddRowAdd one or more rows to a table.

#### AddTableAdd a new table in a text range.

#### AddTextAdd text to a Word document.

#### AppendParagraphAppend a paragraph at the end of the document.

#### AppendTextAppend text to a Word document.

#### CloseClose a document without saving changes.

#### CollapseRangeCollapse a text range to the start or end position.

#### ConfigureCaptionConfigure style of a caption type identified by its label identifier.

#### CopyRangeCopy the contents of a range into another range.

#### CountWordsCount words contained in a Word document.

#### CreateRangeCreate a new text range.

#### CreateRangeAfterCreate a new text range after specified range.

#### CropImageCrop an image at the four borders.

#### DeleteRowDelete a row of a table.

#### DeleteTableDelete a table.

#### DiffWordFilesCompare two Word files visually.

#### ExtendRangeExtend the range indices of a text range.

#### FindStringFind a string in a text range or a document.

#### FormatHeaderRowFormat a row as a header row.

#### GetBookmarkNameGet the name of a bookmark.

#### GetCellRangeReturn a cell of a Word table as a range.

#### GetCellValueReturn the value of a Word table cell.

#### GetColumnRangeReturn a column of a Word table as a selection.

#### GetColumnValuesReturn column values of a Word table as a Tcl list.

#### GetCompatibilityModeReturn the compatibility version of a Word application.

#### GetDocumentIdGet the document identifier of a Word component.

#### GetDocumentIdByIndexFind a document by its index.

#### GetDocumentNameGet the name of a document.

#### GetEndRangeReturn the text range representing the end of the document.

#### GetEnumGet numeric value of an enumeration.

#### GetEnumNameGet name of a given enumeration type and numeric value.

#### GetEnumNamesGet names of a given enumeration type.

#### GetEnumTypesGet available enumeration types.

#### GetEnumValGet numeric value of an enumeration name.

#### GetExtStringReturn the default extension of a Word file.

#### GetImageIdFind an image by its index or name.

#### GetImageListGet a list of images of a Word document.

#### GetImageNameReturn the name of an image.

#### GetListGalleryIdGet one of the 3 predefined list galleries.

#### GetListTemplateIdGet one of the 7 predefined list templates.

#### GetMatrixValuesReturn table values as a matrix.

#### GetNumCharactersReturn the number of characters in a Word document.

#### GetNumColumnsReturn the number of columns of a Word table.

#### GetNumDocumentsReturn the number of documents in a Word application.

#### GetNumImagesReturn the number of images of a Word document.

#### GetNumRowsReturn the number of rows of a Word table.

#### GetNumTablesReturn the number of tables of a Word document.

#### GetPageSetupGet page setup values.

#### GetRangeEndIndexReturn the end index of a text range.

#### GetRangeInformationGet information about a text range.

#### GetRangeStartIndexReturn the start index of a text range.

#### GetRowIdReturn identifier of a Word table row.

#### GetRowRangeReturn rows of a Word table as a range.

#### GetRowValuesReturn row values of a Word table as a Tcl list.

#### GetSelectionRangeReturn the text range representing the current selection.

#### GetStartRangeReturn a text range representing the start of the document.

#### GetTableIdByIndexFind a table by its index.

#### GetTableIdByNameFind table(s) by its name.

#### GetTableNameReturn the name of a table.

#### GetVersionReturn the version of a Word application.

#### InsertCaptionInsert a caption into a range of a document.

#### InsertFileInsert a file into a Word document.

#### InsertImageInsert an image into a range of a document.

#### InsertListInsert a Word list.

#### InsertTextInsert text in a Word document.

#### IsInlineShapeBorders is a property of the Word InlineShape class, but not of class Shape.

#### IsValidCellCheck, if a Word table cell is valid.

#### IsVisibleCheck the visibility of a Word application window.

#### MergeCellsMerge a range of cells.

#### OpenOpen a Word instance. Use an already running instance, if available.

#### OpenDocumentOpen a document, i.e. load a Word file.

#### OpenNewOpen a new Word instance.

#### PrintRangePrint the indices of a text range.

#### QuitQuit a Word instance.

#### ReplaceByProcReplace a string in a text range. Procedural case.

#### ReplaceImageReplace an existing image.

#### ReplaceStringReplace a string in a text range or a document. Simple case.

#### SaveAsSave a document to a Word file.

#### SaveAsPdfSave a document to a PDF file.

#### ScaleImageScale an image.

#### ScreenUpdateToggle the screen updating of a Word application window.

#### SearchSearch or replace a string in a text range or a document. Generic case.

#### SelectRangeSelect a text range.

#### SetCellValueSet the value of a Word table cell.

#### SetCellVerticalAlignmentSet the vertical alignment of a Word table cell.

#### SetColumnsWidthSet the width of a range of table columns.

#### SetColumnValuesInsert column values into a Word table.

#### SetColumnWidthSet the width of a table column.

#### SetCompatibilityModeSet the compatibility mode of a document.

#### SetContentControlDropdown

#### SetContentControlText

#### SetHeaderRowInsert row values into a Word table and format as a header row.

#### SetHeadingFormatSet the HeadingFormat flag of table rows.

#### SetHyperlinkInsert an external hyperlink into a Word document.

#### SetHyperlinkToFileInsert a hyperlink to a file into a Word document.

#### SetImageNameSet the name of an image.

#### SetInternalHyperlinkInsert an internal hyperlink into a Word document.

#### SetLinkToBookmarkInsert an internal link to a bookmark into a Word document.

#### SetMatrixValuesInsert matrix values into a Word table.

#### SetRangeBackgroundColorSet the background color of a table cell range.

#### SetRangeBackgroundColorByEnumSet the background color of a table cell range.

#### SetRangeEndIndexSet the end index of a text range.

#### SetRangeFontBackgroundColorSet the background color of a text range.

#### SetRangeFontBoldToggle the bold font style of a text range.

#### SetRangeFontItalicToggle the italic font style of a text range.

#### SetRangeFontNameSet the font name of a text range.

#### SetRangeFontSizeSet the font size of a text range.

#### SetRangeFontUnderlineToggle the underline font style of a text range.

#### SetRangeHighlightColorByEnumSet the highlight color of a text range.

#### SetRangeHorizontalAlignmentSet the horizontal alignment of a text range.

#### SetRangeMergeCellsMerge a range of cells.

#### SetRangeStartIndexSet the start index of a text range.

#### SetRangeStyleSet the style of a text range.

#### SetRowHeightSet the height of a table row.

#### SetRowValuesInsert row values from a Tcl list.

#### SetTableBorderLineStyleSet the border line styles of a Word table.

#### SetTableBorderLineWidthSet the border line widths of a Word table.

#### SetTableNameSet the name of a table.

#### ShowAlertsToggle the display of Word application alerts.

#### ToggleSpellCheckToggle checking of grammatical and spelling errors.

#### TrimStringTrim a string.

#### UpdateFieldsUpdate all fields as well as tables of content and figures of a document.

#### VisibleToggle the visibility of a Word application window.

Document generated by Ruff!