CAWT 2.4.9 Reference Manual

# ::ExplorerTop, Main

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

## CommandsExplorer, Top, Main

#### FullScreen [::Explorer]Explorer, Top, Main

Toggle the fullscreen mode of an Internet Explorer application window.

FullScreen appId onOff

`appId` | Identifier of the Internet Explorer instance.
`onOff` | If set to true, use fullscreen mode. Otherwise use windowed mode.

Returns no value.

See also: Open, Visible

Show source

    proc ::Explorer::FullScreen {appId onOff} {

        # Toggle the fullscreen mode of an Internet Explorer application window.
        #
        # appId - Identifier of the Internet Explorer instance.
        # onOff - If set to true, use fullscreen mode.
        #         Otherwise use windowed mode.
        #
        # Returns no value.
        #
        # See also: Open Visible

        $appId FullScreen [Cawt TclBool $onOff]
    }

#### Go [::Explorer]Explorer, Top, Main

Go to a specific page.

Go appId target

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

Possible values for target are: `Back`, `Forward`, `Home`, `Search`.

Returns no value.

Show source

    proc ::Explorer::Go {appId target} {

        # Go to a specific page.
        #
        # appId  - Identifier of the Internet Explorer instance.
        # target - String identifying the target page.
        #
        # Possible values for target are: `Back`, `Forward`, `Home`, `Search`.
        #
        # Returns no value.

        set cmd "Go$target"
        eval $appId $cmd
    }

#### IsBusy [::Explorer]Explorer, Top, Main

Check, if an Internet Explorer instance is busy.

IsBusy appId

`appId` | Identifier of the Internet Explorer instance.

Returns true or false dependent on the busy status.

Show source

    proc ::Explorer::IsBusy {appId} {

        # Check, if an Internet Explorer instance is busy.
        #
        # appId - Identifier of the Internet Explorer instance.
        #
        # Returns true or false dependent on the busy status.

        return [expr {[$appId Busy]? true: false}]
    }

#### Navigate [::Explorer]Explorer, Top, Main

Navigate to a URL or local file.

Navigate appId urlOrFile ?wait? ?targetFrame?

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

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.

Returns no value.

See also: Open, OpenNew

Show source

    proc ::Explorer::Navigate {appId urlOrFile {wait true} {targetFrame _self}} {

        # Navigate to a URL or local file.
        #
        # appId       - Identifier of the Internet Explorer instance.
        # urlOrFile   - URL or local file name (as an absolute pathname).
        # wait        - Wait until page has been loaded completely.
        # targetFrame - Name of the frame in which to display the resource.
        #
        # 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.
        #
        # Returns no value.
        #
        # See also: Open OpenNew

        $appId Navigate $urlOrFile 0 $targetFrame
        if { $wait } {
            while {[[$appId Document] readyState] != "complete"} {
                after 100
            }
        }
    }

#### Open [::Explorer]Explorer, Top, Main

Open an Internet Explorer instance.

Open ?visible? ?width? ?height?

`visible` | If set to true, show the application window. Otherwise hide the application window. Optional, default `true`.
`width` | Width of the application window. If negative, open with last used width. Optional, default `-1`.
`height` | Height of the application window. If negative, open with last used height. Optional, default `-1`.

Use an already running Internet Explorer, if available.

Returns the identifier of the Internet Explorer application instance.

See also: OpenNew, Quit, Visible

Show source

    proc ::Explorer::Open {{visible true} {width -1} {height -1}} {

        # Open an Internet Explorer instance.
        #
        # visible - If set to true, show the application window.
        #           Otherwise hide the application window.
        # width   - Width of the application window. If negative, open with last used width.
        # height  - Height of the application window. If negative, open with last used height.
        #
        # Use an already running Internet Explorer, if available.
        #
        # Returns the identifier of the Internet Explorer application instance.
        #
        # See also: OpenNew Quit Visible

        variable explorerAppName

        set appId [Cawt GetOrCreateApp $explorerAppName true]
        Explorer Visible $appId $visible
        if { $width >= 0 } {
            $appId Width [expr $width]
        }
        if { $height >= 0 } {
            $appId Height [expr $height]
        }
        return $appId
    }

#### OpenNew [::Explorer]Explorer, Top, Main

Open a new Internet Explorer instance.

OpenNew ?visible? ?width? ?height?

`visible` | If set to true, show the application window. Otherwise hide the application window. Optional, default `true`.
`width` | Width of the application window. If negative, open with last used width. Optional, default `-1`.
`height` | Height of the application window. If negative, open with last used height. Optional, default `-1`.

Returns the identifier of the new Internet Explorer application instance.

See also: Open, Quit, Visible

Show source

    proc ::Explorer::OpenNew {{visible true} {width -1} {height -1}} {

        # Open a new Internet Explorer instance.
        #
        # visible - If set to true, show the application window.
        #           Otherwise hide the application window.
        # width   - Width of the application window. If negative, open with last used width.
        # height  - Height of the application window. If negative, open with last used height.
        #
        # Returns the identifier of the new Internet Explorer application instance.
        #
        # See also: Open Quit Visible

        variable explorerAppName

        set appId [Cawt GetOrCreateApp $explorerAppName false]
        Explorer Visible $appId $visible
        if { $width >= 0 } {
            $appId Width [expr $width]
        }
        if { $height >= 0 } {
            $appId Height [expr $height]
        }
        return $appId
    }

#### Quit [::Explorer]Explorer, Top, Main

Quit an Internet Explorer instance.

Quit appId

`appId` | Identifier of the Internet Explorer instance.

Returns no value.

See also: Open

Show source

    proc ::Explorer::Quit {appId} {

        # Quit an Internet Explorer instance.
        #
        # appId - Identifier of the Internet Explorer instance.
        #
        # Returns no value.
        #
        # See also: Open

        $appId Quit
    }

#### Visible [::Explorer]Explorer, Top, Main

Toggle the visibility of an Internet Explorer application window.

Visible appId visible

`appId` | Identifier of the Internet Explorer instance.
`visible` | If set to true, show the application window. Otherwise hide the application window.

Returns no value.

See also: Open, OpenNew

Show source

    proc ::Explorer::Visible {appId visible} {

        # Toggle the visibility of an Internet Explorer application window.
        #
        # appId   - Identifier of the Internet Explorer instance.
        # visible - If set to true, show the application window.
        #           Otherwise hide the application window.
        #
        # Returns no value.
        #
        # See also: Open OpenNew

        $appId Visible [Cawt TclInt $visible]
    }

# Start page

# Cawt

# Office

# Excel

# Ppt

# Word

# Outlook

# OneNote

# Office::Enum

# Excel::Enum

# Ppt::Enum

# Word::Enum

# Outlook::Enum

# OneNote::Enum

# Earth

# Explorer

# Ocr

# Reader

# Matlab

# Explorer

## Commands

#### FullScreen Toggle the fullscreen mode of an Internet Explorer application window.

#### Go Go to a specific page.

#### IsBusy Check, if an Internet Explorer instance is busy.

#### Navigate Navigate to a URL or local file.

#### Open Open an Internet Explorer instance.

#### OpenNew Open a new Internet Explorer instance.

#### Quit Quit an Internet Explorer instance.

#### Visible Toggle the visibility of an Internet Explorer application window.

Document generated by Ruff!