Top  | Previous | Next

Document Viewer

display_DocViewer

Description

The document viewer is capable of loading and displaying a document that is available over the network at a URL. It is capable of displaying simple HTML and RTF documents. Although HTML links will be followed, it is not a fully functional interactive web browser. Its HTML support is rudimentary at best, and there is no JavaScript support. See the system.net.openURL function for a more robust solution for launching webpages, PDFs, etc.

 

This is component is useful for viewing machine manuals or operator protocol in HTML or RTF format. Note that in addition to HTML URLs (like "http://www.google.com"), you can load files as well using the URL format for files. Some examples:

file://localhost/C:/myfolder/file.txt
file://MyFileServer/resources/manuals/instructions.rtf"

Properties

Appearance

Font

Font of text of this component

Scripting name

font

Data type

Font

Foreground Color

The foreground color of the component.

Scripting name

foreground

Data type

Color

Background Color

The background color of the component.

Scripting name

background

Data type

Color

Antialias

Draw with antialias on? Makes text smoother

Scripting name

antialias

Data type

boolean

Flags

expert

Behavior

Link Action

What happens when the user clicks on a hyperlink inside this document, if it is an HTML document.

Scripting name

linkAction

Data type

int

Values

0

Launch Externally

1

Launch Internally

2

Fire Event

Common

Name

The name of this component.

Scripting name

name

Data type

String

Flags

bindable

Enabled

If disabled, a component cannot be used.

Scripting name

componentEnabled

Data type

boolean

Visible

If disabled, the component will be hidden.

Scripting name

visible

Data type

boolean

Flags

bindable

Border

The border surrounding this component. NOTE that the border is unaffected by rotation.

Scripting name

border

Data type

Border

Mouseover Text

The text that is displayed in the tooltip which pops up on mouseover of this component.

Scripting name

toolTipText

Data type

String

Opaque

If false, backgrounds are not drawn. If true, backgrounds are drawn.

Scripting name

opaque

Data type

boolean

Data

Page URL

Set this to a URL to display that page. If the url startswith '/', it is assumed to be relative to the Gateway's HTTP address.

Scripting name

page

Data type

String

Flags

bindable

Content Type

The content type of this document. Example: text/html

Scripting name

contentType

Data type

String

Text

The text of the document. Should match the content type

Scripting name

text

Data type

String

Flags

bindable

Scripting

Events

The following event sets are fired by this component. See Component Event Handlers to learn more.

mouse
hyperlink
mouseMotion
focus
propertyChange
key

 

Scripting Functions

This component has no special scripting functions.