Property and Event Reference



Chapter 4   Form Properties

List of properties   Top of page

Here are the form properties:

Alignment
Automatic Query
Background Color
Background Image
Background Image Mode
Border Style
Business Object Name
Button Type
Cancel Button
Caption Expression
Caption Text
Checked Value
Choices
Color
Column Expressions
Control Type
Dark Shadow Color
Data Column
Data Type
Data Value
Database Column
Default Button
Disabled Image
Display Format
Display Value
Distinct
Down Image
Editable
Enabled
Events Produced
Font Name
Font Size
Font Style
Height
Help Page
Highlight Color

Horizontal Alignment
Horizontal Scrollbar
Horizontal Text Position
Hover Image
Hover Mode
Hover Text Color
Image
Image Dialog
Image Drawing Mode
Image Expression
Inactive Tab Color
Increment
Initial Data Mode
Initial Value
Interval
Inverted
Justification
Left
Limit Rows
Line Wrap
Line Wrap Style
Link Clause
Link Dialog
Load Choices
Load Data
Major Tick Spacing
Max Length
Maximum Rows
Max Value
Maximum Value
Min Length
Min Value
Minimum Value
Minor Tick Spacing

Name
Normal Image
Order By
Orientation
Pane Captions
Pane Images
Panes
Parameters
Pressed Image
Radio Button Group
Raw HTML Dialog
Rollover Image
Shadow Color
Show Labels
Show Ticks
Show Validation Errors
Snap To Ticks
Start Automatically
Storage Value
Table
Text Color
Text Style
Tool Tip
Toolbar
Top
Transparent
Unchecked Value
Up Image
Validation Rules
Values
Vertical Alignment
Vertical Scrollbar
Vertical Text Position
Visible
Where Clause
Width
Word Wrap

Alignment   Top of page

The position of the text in the field.

Usage

Applies to AgcJTextField.

Values are Left, Centered, Right.

An alignment setting is not available for the AWT-based AgcTextField. It is a feature provided by the Swing package.

See also

Justification for AgcLabel; Horizontal Alignment, Horizontal Text Position for AgcJLabel

getJustification(), setJustification()

Automatic Query   Top of page

Specifies whether to automatically fill the control with data or wait until the query(), refreshRows(), or other methods of AgcData is called.

Usage

Applies to AgcChoice, AgcComboBox, AgcList, AgcTreeControl, AgcViewDownloadable, AgcJComboBox, AgcJList.

If a Link Clause that references the parent form is specified, then the Automatic Query property is ignored.

See also

Link Clause

Background Color   Top of page

Specifies the control's background color.

Usage

Applies to AgcIntegerSpinnerField, AgcLabel, AgcTabControl, AgcTextArea, AgcTextField, AgfForm, AgcJIntegerSpinnerField, AgcJLabel, AgcJTabbedPane, AgcJTextArea, AgcJTextField.

See also

Background Image, Background Image Mode, Dark Shadow Color, Highlight Color, Inactive Tab Color, Shadow Color, Text Color

Component.getBackground(), Component.setBackground()

Background Image   Top of page

Specifies the name and location of an image to display on the form.

Usage

Applies to AgfForm.

For information on URLs and cropping specifications for images, see the Image property.

See also

Background Image Mode

AgiControl.getBackgroundImage(), AgiControl.setBackgroundImage()

Background Image Mode   Top of page

Specifies the way in which the form displays its background image.

Usage

Applies to AgfForm.

The values for the form control include:

This mode . . .

displays the image this way . . .

Normal

Displays a single image at its original size in the upper left corner of the form.

Centered

Displays a single image at its original size centered on the form.

Tiled

Displays multiple copies of the image, repeating the image to fill the form.

Stretched

Displays a single image that is stretched to fill the entire form.

See also

Background Image Mode

AgiControl.getBackgroundImageMode(), AgiControl.setBackgroundImageMode()

Border Style   Top of page

Defines the control's border style.

Usage

Applies to AgcLabel, AgcRectangle, AgcJLabel.

You can select these border styles in the Property Inspector: None, Outline, Lowered, Raised, Grooved. The default for labels is None and the default for rectangles is Grooved.

See also

AgcRectangle.getBorderStyle(), AgcRectangle.setBorderStyle() , AgcLabel.getBorderStyle(), AgcLabel.setBorderStyle()

Business Object Name   Top of page

The name of a data source triggered business object that supplies a dataset for AgcData.

Usage

Applies to AgcData.

See also

Using Data Source Objects in the Programmer's Guide

Data source example in Application Techniques

Button Type   Top of page

Specifies the button type of an Image Button so that it behaves like a push button, a radio button, or a toggle button.

Usage

Applies to AgcButtonImage.

Types are Push, Toggle, and Radio.

Assigning a type to an Image Button gives the button some of the properties of that type. For example, if Button Type is Radio, you can specify a Radio Button Group for the Image button. Note, however, that even though the button type affects some of the properties of the image button, image buttons are always instances of the AgcButtonImage class.

See Also

AgcButtonCheck, AgcButtonRadio, AgcButtonText, AgcButtonRaw, AgcJCheckBox, AgcJRadioButton, AgcJButtonToggle, JButton (in JDK)

Cancel Button   Top of page

Indicates whether the button is the Cancel button for the form.

Usage

Applies to AgcButtonImage, AgcButtonText, AgcJButton.

When a button is defined as the cancel button for a form, its actionPerformed event fires when the user presses the ESC key while focus is anywhere on the form.

A button can be both the default button and the cancel button.

See also

Default Button

Caption Expression   Top of page

Specifies a String expression whose value is displayed as the control's built-in label at runtime.

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcLabel, AgcJButton, AgcJCheckBox, AgcJLabel, AgcJRadioButton.

Use the Caption Text property to define a static string. If both a Caption Expression and Caption Text property value are specified, Caption Expression overrides Caption Text.

Use the Text Color, Text Style, and Font properties to customize the appearance of the text.

Example

This expression displays today's date and the company name when the table associated with the form is companies.

  today() + " " + companyname 

See also

Caption Text, Font Name, Font Size, Font Style, Text Color, Text Style, Tool Tip

Caption Text   Top of page

Specifies a static text string for the control's built-in label.

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcLabel, AgcRectangle, AgcJButton, AgcJCheckBox, AgcJLabel, AgcJRadioButton.

For buttons and labels, you can specify a static text string in the Caption Text property, or an expression that evaluates to the label text at runtime using the Caption Expression property. If you specify both, the text expression is used.

When a Rectangle control surrounds a group of Radio Buttons, use the caption text to identify the purpose of the buttons.

Use the Text Color, Text Style, and Font properties to customize the appearance of the text.

See also

Caption Text, Font Name, Font Size, Font Style, Text Color, Text Style, Tool Tip

Checked Value   Top of page

Specifies the value that gets written to the database when the Check Box control is checked.

Usage

Applies to AgcButtonCheck, AgcJCheckBox.

To bind the Check Box control to a database column, specify a value for the Data Column property. For a bound Check Box control, the Checked Value property is the value written to the database if the check box is checked. When the check box is not checked, the value of the Unchecked Value property is written to the database. If no Checked Value is specified, the value "true" is written to the database when the check box is checked.

See also

Unchecked Value, Data Column

AgcButtonRaw.setCheckedValue(), AgcJCheckBox.getCheckedValue(), AgcJCheckBox.setCheckedValue()

Choices   Top of page

Specifies a list of items that is displayed in the control.

Usage

Applies to AgcChoice, AgcComboBox, AgcList, AgcTreeControl, AgcJComboBox, AgcJList.

To load the control with data from this list, the Load Choices property must be set to Statically. When Load Choices is set to From Table, SilverStream loads list items from a database table instead.

To enter a list of choices, display the Edit Property dialog box and enter each choice on a separate line.

See also

Load Choices, Values

Color   Top of page

Specifies the rectangle's fill and border color.

Usage

Applies to AgcRectangle.

If no color is specified, the rectangle's fill color defaults to gray.

If Transparent is set to true, only the border shows the color and the interior show whatever is behind the rectangle. When Transparent is false, the color fills the rectangle.

See also

Background Color, Dark Shadow Color, Highlight Color, Hover Text Color, Inactive Tab Color, Shadow Color, Text Color, Transparent

AgcRectangle.getColor(), AgcRectangle.setColor()

Column Expressions   Top of page

One or more expressions that associate a property name with a database column or expression. Data is retrieved for each column expression.

Usage

Applies to AgcData.

Column expressions can combine columns and other data.

At runtime, a column expression is a property of the AgcData control. You can refer to properties by name or index number. You can get and set the values of the properties for the current row.

You can navigate through the retrieved rows using methods of the AgcData's AgiRowCursor interface. You can use methods of AgiBindingMgr to bind columns of AgcData objects to fields on the form.

Example

Name: CName
Expression: companies.companyname

Name: CityState
Expression: companies.city + ", " + companies.stateid + " " + companies.postalcode

See also

Table

AgcData: getProperty(), getPropertyCount(), getPropertyName(), getPropertyIndex(), setProperty()

Data Access Basics in the Programmer's Guide

Control Type   Top of page

Specifies the type of control. The value displayed for the Control Type property is similar to the class name of the control without the Agc prefix. Swing-based types begin with "J". Other values are AWT-based types.

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcChoice, AgcComboBox, AgcFileAttachment, AgcHTMLEditControl, AgcImage, AgcIntegerSpinnerField, AgcLabel, AgcList, AgcRectangle, AgcTabControl, AgcTextArea, AgcTextField, AgcTreeControl, AgcView, AgcJButton, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJLabel, AgcJList, AgcJRadioButton, AgcJSlider, AgcJTabbedPane, AgcJTextArea, AgcJTextField.

You can convert controls from one type to another by changing their Control Type. Some property values are carried over if they are applicable to the new type.

To change several controls at once, select all the controls and then select a Control Type.

For text fields, you can also specify a data type, which restricts the type of data the user can enter in the field and changes the class of the control.

See also

Button Type, Data Type

Dark Shadow Color   Top of page

Specifies the dark shadow color used in the border of the tab control.

Usage

Applies to AgcTabControl, AgcJTabbedPane.

See also

Background Color, Highlight Color, Inactive Tab Color, Shadow Color, Text Color

AgcTabControl.setDarkShadowColor(), AgcTabControl.getDarkShadowColor()

Data Column   Top of page

Specifies the name of the database column to which the control is bound.

Usage

Applies to AgcButtonCheck, AgcButtonRadio, AgcChoice, AgcComboBox, AgcHTMLEditControl, AgcIntegerSpinnerField, AgcList, AgcTextArea, AgcTextField, AgcTreeControl, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJList, AgcJRadioButton, AgcJSlider, AgcJTextArea, AgcJTextField.

When a control is bound to a database column, the control displays the value in the current row for that column. The user can change the value, which becomes the value updated in the database.

The Data Column property binds a control to a database column, a property of an AgcData control, or another control. Click the ellipses button to display a list of choices. The list includes the main table associated with the form and its columns, related tables and their columns, and any AgcData controls on the form and their named column expressions.

You can associate a table with the form in in the Form Wizard when you create the form, or you can do it later in the Form Designer. To specify a table in the Designer, click the Data icon in the gallery and use the Relational Data Palette to select a table.

See also

AgcData, Accessing Data in the Programmer's Guide

Data Type   Top of page

Specifies the type of data to be displayed in the input field.

Usage

Applies to AgcTextField, AgcJTextField.

Selecting a field type changes the class instantiated for the control.

This choice . . .

creates this object type . . .

String

AgcTextField or AgcJTextField

Integer

AgcIntegerField or AgcJIntegerField

BigDecimal

AgcBigDecimalField or AgcJBigDecimalField

Double

AgcDoubleField or AgcJDoubleField

Date

AgcDateField or AgcJDateField

Time

AgcTimeField or AgcJTimeField

Timestamp

AgcTimestampField or AgcJTimestampField

Password

AgcPasswordField or AgcJPasswordField

The field displays asterisks instead of the characters the user enters.

Using the Data Type property does some data validation without validation rules or coding the validationTest event. If the user leaves the field and has entered characters that don't match the data type, a validationFailed event is fired.

See also

Control Type, Show Validation Errors, Validation Rules

Data Value   Top of page

Specifies the value that is stored in the database when the radio button is the selected button in the button group.

Usage

Apples to AgcButtonRadio, AgcJRadioButton.

See also

Checked Value

AgcButtonRaw.setCheckedValue(), AgcJRadioButton.getCheckedValue(), AgcJRadioButton.setCheckedValue()

Database Column   Top of page

Specifies the name of the database column which holds the file associated with the AgcFileAttachment control.

Usage

Applies to AgcFileAttachment.

To store a non-text file in the database, the data column must be a long varbinary column.

For information on programming for file attachments, see the File attachments section in the Advanced Form Topics chapter of the Programmer's Guide.

Default Button   Top of page

Indicates whether the button is the default button for the form.

Usage

Applies to AgcButtonImage, AgcButtonText, AgcJButton.

When a button is the default button, its actionPerformed event fires when the user presses Enter while on the form regardless of the control that has focus (unless the control that has focus supports an event for the Enter key, for example Text Area).

A button can be both the default button and the cancel button.

See also

Cancel Button

Disabled Image   Top of page

Specifies an image to display when the button is disabled.

Usage

Applies to AgcJButton.

For information on URLs and cropping specifications for images, see the Image property.

See also

Normal Image, Pressed Image, Rollover Image

getDisabledIcon(), setDisabledIcon()

Display Format   Top of page

Specifies a pattern or style for the contents of the input field (e.g., currency). Formats are listed in the General Reference.

Usage

Applies to AgcIntegerSpinnerField, AgcTextField, AgcJIntegerSpinnerField, AgcJTextField. A text field with a non-string data type is subclassed to either AgcValueField or AgcJValueField.

When you choose a data type other than String for a text field, you can specify either a pattern or named display style for the Display Format property.

See also

Data Type, Display Formats in the General Reference

getDisplayPattern(), setDisplayPattern(), getDisplayStyle(), setDisplayStyle()

Display Value   Top of page

Specifies the name of the database column whose values are displayed in a list control.

Usage

Applies to AgcChoice, AgcComboBox, AgcList, AgcTreeControl, AgcJComboBox, AgcJList.

To load a list from a database table:

  1. Set the Load Choices property to From Table.

  2. Specify the name of the database table in the Table property.

  3. Specify a column whose values you want to display in the Display Value property.

The display value can be a single field or an expression combining fields, constants, and functions. For example, the list can display an employee's full name by concatenating the lastname and firstname fields.

The list can also be bound to a database column so that the selected item in the list is the value updated in the database.

You can use Display Value with the Storage Value property, so that the list displays one set of values but sends a different set of values to the database. For example, the list can display product names, but store product IDs.

See also

Load Choices, Storage Value, Table

Distinct   Top of page

Specifies whether the retrieved rows represent unique values. Duplicate values are eliminated.

Usage

Applies to AgcChoice, AgcComboBox, AgcData, AgcList, AgcTreeControl, AgcViewDownloadable, AgfForm, AgcJComboBox, AgcJList.

When the Distinct property is turned on, the SQL statements generated by the form uses the SQL keyword DISTINCT. This means that each row retrieved is unique.

For example, suppose a table named people contained three fields: First Name, Middle Name, and Last Name. For the SQL statement SELECT DISTINCT * FROM people, you could get both Bob J. Smith and Bob A. Smith; but if the statement was SELECT DISTINCT firstname, lastname FROM people, you would get Bob Smith only once since without the middle initial these records appear the same.

For list controls, turning on Distinct means that each display/storage value pair will be unique. If you had a storage column value that was identical in two different rows, but with different display column values, these would be considered distinct, and the user would see several display values associated with the same storage value.

Distinct is most useful when the set of columns being retrieved does not include the primary key (which must be unique across all rows) or when the table does not have a primary key.

See also

Display Value, Limit Rows, Load Choices, Maximum Rows, Storage Value, Table

Down Image   Top of page

Specifies an image to display when the button is pressed.

Usage

Applies to AgcButtonImage.

For information on URLs and cropping specifications for images, see the Image property.

See also

Up Image

AgcButtonRaw.setUpImage(), AgcButtonRaw.getUpImage()

Editable   Top of page

Specifies whether the user can edit the contents of the control.

Usage

Applies to AgcComboBox, AgcIntegerSpinnerField, AgcTextArea, AgcTextField, AgcJComboBox, AgcJIntegerSpinnerField, AgcJTextArea, AgcJTextField.

See also

Enabled, Visible

AgcComboBox.getEditable(), AgcIntegerSpinnerField.getEditable(), TextComponent.isEditable(), JComboBox.isEditable(), AgcJIntegerSpinnerField.isEditable(), JTextComponent.isEditable()

setEditable()

Enabled   Top of page

Specifies whether the control is enabled when the form is displayed.

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcChoice, AgcComboBox, AgcHTMLEditControl, AgcImage, AgcIntegerSpinnerField, AgcLabel, AgcList, AgcRectangle, AgcTabControl, AgcTextArea, AgcTextField, AgcTreeControl, AgcView, AgcJButton, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJLabel, AgcJList, AgcJRadioButton, AgcJSlider, AgcJTabbedPane, AgcJTextArea, AgcJTextField.

See also

Editable, Visible

setEnabled(), isEnabled()

Events Produced   Top of page

Events that a form produces when it is used as a subform.

Usage

Applies to AgfForm.

You can specify as many events as you need by clicking Add New Event.

The event names should describe the event; you might use names like UPDATE, REFRESH. The names can include letters, numbers, and underscores. In the form code, the identifiers are actually numeric constants. SilverStream converts the name you enter to uppercase, following the Java convention for constants.

To implement programmer-defined events, you do the following:

When you are working on the parent form in the Form Designer, you add the subform to the parent form, which makes the programmer-defined events available in the Programming Editor. The event names use the identifiers you specified in the subform's definition. You write code for the events on the parent form. When you are working on the subform's definition in the Form Designer, you can write code for the subform's standard events, but not the programmer-defined events.

For more information, see the chapter on programming forms in the Programmer's Guide.

Font Name   Top of page

Specifies the name of the font used for the text in the control.

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcChoice, AgcComboBox, AgcIntegerSpinnerField, AgcLabel, AgcList, AgcRectangle, AgcTabControl, AgcTextArea, AgcTextField, AgcTreeControl, AgcJButton, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJLabel, AgcJList, AgcJRadioButton, AgcJTabbedPane, AgcJTextArea, AgcJTextField.

In the Designer, you can choose among these Java fonts: Dialog, SansSerif, Serif, Monospaced, DialogInput. SilverStream also supports these named Java fonts: Helvetica, TimesRoman, Courier, Zapfdingbats. At runtime, Java translates the font name to the appropriate font installed on the system.

See also

Font Size, Font Style

getFontIdentifier(), setFontIdentifier()

Font Size   Top of page

Specifies the point size of the font used for the text in the control.

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcChoice, AgcComboBox, AgcIntegerSpinnerField, AgcLabel, AgcList, AgcRectangle, AgcTabControl, AgcTextArea, AgcTextField, AgcTreeControl, AgcJButton, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJLabel, AgcJList, AgcJRadioButton, AgcJTabbedPane, AgcJTextArea, AgcJTextField.

See also

Font Name, Font Style

getFontIdentifier(), setFontIdentifier()

Font Style   Top of page

Specifies the style of the font used for text in the control. The font styles include: Normal, Bold, Italic, and Bold Italic.

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcChoice, AgcComboBox, AgcIntegerSpinnerField, AgcLabel, AgcList, AgcRectangle, AgcTabControl, AgcTextArea, AgcTextField, AgcTreeControl, AgcJButton, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJLabel, AgcJList, AgcJRadioButton, AgcJTabbedPane, AgcJTextArea, AgcJTextField.

See also

Font Name, Font Size

getFontIdentifier(), setFontIdentifier()

Height   Top of page

Specifies the control's height in pixels.

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcChoice, AgcComboBox, AgcHTMLEditControl, AgcImage, AgcIntegerSpinnerField, AgcLabel, AgcList, AgcRectangle, AgcTabControl, AgcTextArea, AgcTextField, AgcTreeControl, AgcView, AgcViewDownloadable, AgfForm, AgcJButton, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJLabel, AgcJList, AgcJRadioButton, AgcJSlider, AgcJTabbedPane, AgcJTextArea, AgcJTextField.

Note that the control's size (Width and Height) is represented in the database relative to the system's font sizes, ensuring that the control is displayed properly on a system whose default fonts differ from the default fonts on which the control was designed.

See also

Left, Top, Width

Methods of JComponent or Component: getBounds(), getHeight(), getSize(), setBounds(), setSize()

Help Page   Top of page

Specifies an HTML file that contains help text associated with the control. The Help Page can either be the name of a page in the application's database, the name of a page in a different database (database:pagename), or a full URL to a help page.

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcChoice, AgcComboBox, AgcHTMLEditControl, AgcIntegerSpinnerField, AgcList, AgcTextArea, AgcTextField, AgcTreeControl, AgcView, AgfForm, AgcJButton, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJList, AgcJRadioButton, AgcJSlider, AgcJTextArea, AgcJTextField.

When the user presses F1 while the control has focus, SilverStream opens a new browser window and displays this page.

If no Help Page is specified and the user presses the F1 key, then the containing control is searched for a Help Page to display. If the containing control does not have a Help Page, then the next containing control is searched, and so on until either a Help Page is found or the form is reached. This Help Page strategy enables the programmer to determine the level of granularity of the help provided.

A browser is opened only if a Help Page is defined.

See also

AgiControl.setHelpInfo(), AgiControl.getHelpInfo()

Highlight Color   Top of page

Sets the color for the highlight effect on the text of the control.

Usage

Applies to AgcLabel, AgcTabControl, AgcJLabel, AgcJTabbedPane.

For labels, the highlight color is only used when the Text Style is Embossed.

See also

Background Color, Dark Shadow Color, Inactive Tab Color, Shadow Color, Text Color

AgcTabControl.setHighlightColor(), AgcTabControl.getHighlightColor(), , AgcJTabControl.setLightHighlightColor(), AgcJTabControl.getLightHighlightColor(), AgcLabel.setTextHighlightColor(), AgcLabel.getTextHighlightColor(), AgcJLabel.setTextHighlightColor(), AgcJLabel.getTextHighlightColor()

Horizontal Alignment   Top of page

The horizontal position of the image and text within the bounds of the label control.

Usage

Applies to AgcJLabel, AgcJButton.

The Horizontal Alignment property positions the image and text as a unit. To change the relative positions of the image and text, use the Horizontal Text Position property.

See also

Horizontal Text Position, Vertical Alignment, Vertical Text Position

Horizontal Scrollbar   Top of page

Specifies whether the control displays a horizontal scrollbar at runtime.

Usage

Applies to AgcTextArea, AgcJTextArea.

See also

Vertical Scrollbar

Horizontal Text Position   Top of page

Specifies the horizontal position of the text in the label control relative to the image.

Usage

Applies to AgcJLabel, AgcJButton.

Values are Right of image, Center, Left of image. When both Vertical and Horizontal Text Position are Center, the text displays in front of the image.

See also

Horizontal Alignment, Vertical Alignment, Vertical Text Position

Hover Image   Top of page

Specifies the image to be displayed when the cursor hovers over the control.

Usage

Applies to AgcButtonImage.

The Hover Image is only displayed when Hover Mode is set to true.

For information on URLs and cropping specifications for images, see the Image property.

See also

Hover Mode, Hover Text Color

AgcButtonRaw.setHoverImage(), AgcButtonRaw.getHoverImage()

Hover Mode   Top of page

Specifies whether the Hover Image or Hover Text Color is displayed.

Usage

Applies to AgcButtonImage.

When the Hover Mode is set to false (the default), the Hover Image and the Hover Text Color are not displayed.

See also

Hover Image, Hover Text Color

AgcButtonRaw.setHoverMode(), AgcButtonRaw.getHoverMode()

Hover Text Color   Top of page

Specifies the color for the control's Caption when the cursor hovers over the control.

Usage

Applies to AgcButtonImage.

When the Hover Mode is set to false (the default), the Hover Text Color is not displayed.

See also

Hover Image, Hover Mode

AgcButtonRaw.setHoverTextColor(), AgcButtonRaw.getHoverTextColor()

Image   Top of page

Specifies the image displayed by the control.

Usage

Applies to AgcImage, AgcJLabel.

You can open the Edit Property dialog box to select an image from an attached database or enter the filename yourself. The way you specify the file name depends on where the image is.

If the image is . . .

specify . . .

In the same SilverStream database

The file name; for example, logo.gif

In another SilverStream database on the same server

The database and file name, separated by a colon; for example, Silvermaster35:logo.gif

On another web server

the fully qualified URL; for example, http://www.otherserver.com/image.gif

For AgcImage, you can use the Image Expression property instead. Use it to specify an expression that evaluates to an image URL at runtime. If you specify values for both Image Expression and Image, Image Expression is used and the value of Image is ignored.

To use part of a larger image, specify the pixel coordinates of the portion of the image you want to use. The full syntax is:

  imageurl x y width height  

For more information, see the section on cropping a larger image in the Form Designer section of the Tools Guide.

See also

Image Drawing Mode, Image Expression, Pane Images

Image Dialog   Top of page

The name of a form that SilverStream displays when the user clicks the Insert Image toolbar button in the HTML Edit Control.

Usage

Applies to AgcHTMLEditControl.

SilverStream displays the form you specify by calling the showFormDialog() method. When the user closes the form, the form must call the closeDialog() method. The method's argument is the URL of the image file to be inserted in the HTML Edit Control. The URL can be an absolute URL, or a relative URL referring to an image in the current SilverStream database.

If you don't specify a form in Image Dialog, the HTML Edit Control displays a default dialog for selecting an image.

URLs for images on the SilverStream server

The objects in a SilverStream database are in subdirectories below the SilverStream directory. To refer to an image in the current database, specify:

  SilverStream/Objectstore/Images/filename.ext 

To refer to an image in another database on the same server, specify the database name, beginning with a slash:

  /Otherdatabase/SilverStream/Objectstore/Images/filename.ext 

If the image is in the SilverMaster database, you don't need to specify the database name:

  /SilverStream/Objectstore/Images/filename.ext 

Context base

The default context base for relative URLs is the "current" database, which is the database containing the form that has the HTML Edit Control. For example, suppose that frmMain contains an HTML Edit Control and resides in MyDatabase; a relative URL passed by the closeDialog() method is relative to http://hostname/MyDatabase/. An URL that begins with a slash is relative to the server: http://hostname/.

If your application has its own image store, perhaps provided by a servlet, the Image dialog might return something like MyServlet?ImageID=10023. This would result in a full URL of http://hostname/MyDatabase/MyServlet?ImageID=10023.

You can change the base for relative URLs within the HTML Edit Control with the setContextBase() method. The HTML created in the HTML Edit Control is application data and can be used in other contexts. You might change the context base if the HTML will ultimately be delivered in some other environment, such as from a servlet in some other location.

Example

Suppose that the form frmMain includes an HTML Edit Control. For the control's Image Dialog property, you specify frmImagePicker, which is in the same database as frmMain. The field fldImageName on frmImagePicker holds the image file name the user selected. In the actionPerformed event for the OK button of frmImagePicker, this code calls closeDialog() with the image file name as its argument.

  closeDialog( fldImageName.getText() ); 

See also

Link Dialog, Raw HTML Dialog, Toolbar

AgcHTMLEditControl.setContextBase()

Image Drawing Mode   Top of page

Specifies how the control displays the image.

Usage

Applies to AgcImage.

This mode . . .

displays the image this way . . .

Normal

Displays a single image at its original size in the upper left corner of the control.

Centered

Displays a single image at its original size centered in the control.

Tiled

Displays multiple copies of the image, repeating the image to fill the control.

Stretched

Displays a single image that is stretched to fill the control.

See also

Image, Image Expression, Background Image Mode (for a form's background image)

Image Expression   Top of page

Specifies a String expression whose value is the image name. The expression is evaluated at runtime and the control displays the image.

Usage

Applies to AgcImage.

To specify a static image file name, use the Image property.

Image Expression could specify the image in many ways: for example, the name of the image might be stored in a database column, or the image file could be stored as a file attachment. For information on URLs and cropping specifications for images, see the Image property.

If you specify values for both Image Expression and Image, Image Expression is used and the value of Image is ignored.

Example

This expression displays a different image depending on the hour of the day:

  if (hour(now()) >= 13) then "silvermaster35:ab2a.gif" else   "silvermaster35:ab2b.gif" endif 

This example displays a different image depending on the value in an integer input field:

  if ( fldTree >= 5) then "silvermaster35:ab2a.gif" else   "silvermaster35:ab2b.gif" endif 

See also

Image, Image Drawing Mode

Inactive Tab Color   Top of page

Specifies the color of the tabs that are not selected.

Usage

Applies to AgcTabControl, AgcJTabbedPane.

See also

Background Color, Dark Shadow Color, Highlight Color, Shadow Color, Text Color

AgcTabControl.getInactiveTabColor(), AgcTabControl.setInactiveTabColor()

Increment   Top of page

Specifies an integer amount used to increment or decrement the Integer Spinner's value when the user clicks an arrow.

Usage

Applies to AgcIntegerSpinnerField, AgcJIntegerSpinnerField.

See also

AgcIntegerSpinnerField.setIncrement(), AgcIntegerSpinnerField.getIncrement()

Initial Data Mode   Top of page

Specifies how the form loads data when the form is instantiated.

Usage

Applies to AgfForm.

When you create a new form using the Form Wizard, you are prompted to choose an initial data mode. You can change the value of Initial Mode under the Data heading in the Property Inspector.

This mode . . .

Has this effect on data loading . . .

First Record

The form loads all the data from the server and the form's controls display the first database record. If the form's dataset is large, there can be a long delay before the form is displayed. To reduce the size of the dataset, specify a Where clause in the Property Inspector or in the query() method at runtime (same as calling the agData.first() method in the formLoaded event).

It has this constant: DATA_MODE_FIRST_RECORD.

Find Mode

The form does not load any data from the server.The form's controls do not display data. The form is initially in find mode. (same as calling the beginFind() method.)

It has this constant: DATA_MODE_FIND.

Insert Only

The form does not load any data from the server. The form's controls do not display data. Users can add database records.

It has this constant: DATA_MODE_INSERT_ONLY.

No Automatic Query

No data is loaded to the form. To retrieve data, call the query() method with an optional Where clause.

It has this constant: DATA_MODE_NORMAL.

Initial Value   Top of page

Specifies the slider's initial runtime value.

Usage

Applies to AgcJSlider.

In the Property Inspector, the initial value you specify must be between or equal to the minimum and maximum values.

See also

Maximum Value, Minimum Value

Interval   Top of page

Specifies an amount of time, in seconds, between timeIntervalExpired events.

Usage

Applies to AgcTimer.

When the interval has elapsed, the timeIntervalExpired event is fired and the timer restarts. To stop the timer, call the stopTimer() method.

See also

Start Automatically

getInterval(), setInterval()

Inverted   Top of page

Reverses the scale on the slider.

Usage

Applies to AgcJSlider.

When the slider is not inverted, the minimum value is on the left when the orientation is horizontal, or at the bottom when the orientation is vertical.

When Inverted is selected, the minimum value is on the right instead of the left when the orientation is horizontal, or the top instead of the bottom when the orientation is vertical.

See also

Orientation

Justification   Top of page

The horizontal position of the label text.

Usage

Applies to AgcLabel.

Values are Left, Centered, Right.

See also

Alignment for AgcJTextField; Horizontal Alignment, Horizontal Text Position for AgcJLabel

getJustification(), setJustification()

Left   Top of page

Specifies the location of the upper left corner of the control in pixels, relative to the control's container (e.g., a form control).

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcChoice, AgcComboBox, AgcHTMLEditControl, AgcImage, AgcIntegerSpinnerField, AgcLabel, AgcList, AgcRectangle, AgcTabControl, AgcTextArea, AgcTextField, AgcTreeControl, AgcView, AgcViewDownloadable, AgcJButton, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJLabel, AgcJList, AgcJRadioButton, AgcJSlider, AgcJTabbedPane, AgcJTextArea, AgcJTextField.

See also

Top, Width, Height

Component.getLocation(), Component.setLocation()

Limit Rows   Top of page

Specifies whether an upper limit is in effect for the number of rows retrieved.

Usage

Applies to AgcChoice, AgcComboBox, AgcData, AgcList, AgcTreeControl, AgcViewDownloadable, AgfForm, AgcJComboBox, AgcJList.

Limit Rows takes effect when Maximum Rows is set to a value other than 0.

For AgfForm, the limit applies to the number of rows retrieved by the AgData control. For the various list and tree controls, the limit applies when Load Choices is From Table and affects the number of items retrieved for the list.

For AgcViewDownloadable, the limit applies to the rows displayed. The user can scroll to additional groups of rows. The full result set is always retrieved.

See also

Distinct, Load Choices, Maximum Rows

Line Wrap   Top of page

Specifies whether text wraps to the next line when the text reaches the right edge of the text area control.

Usage

Applies to AgcTextArea, AgcJTextArea.

If Line Wrap is off and text extends beyond the edge of the control, a horizontal scrollbar automatically appears. The user can put text on the next line by pressing Enter.

See also

Line Wrap Style

JTextArea.getLineWrap(), JTextArea.setLineWrap()

Line Wrap Style   Top of page

Specifies whether a line break occurs only between words or between individual characters.

Usage

Applies to AgcTextArea, AgcJTextArea.

Values are Wrap Words and Wrap Characters. The wrap style takes effect when Line Wrap is true.

When set to Wrap Characters, each line in the text area is completely filled to the right margin before text wraps to the next line. A break can occur in the middle of a word and a subsequent line can begin with a space.

When set to Wrap Words, breaks occur only when a space or punctuation occurs in the text.

See also

Line Wrap

Link Clause   Top of page

Specifies a link between the data of the form and a child of the form.

Usage

Applies to AgcViewDownloadable, subforms.

The Link clause identifies the relationship between data on the main form and a child form. Using a Link clause, a child form can display a set of records from another table related to a master record displayed on the main form.

The Link clause describes a join operation between the datasets of the form and a child form. It becomes part of the Where clause used in the database query for the child form. If the child form already has a Where clause, the Link clause is ANDed with it. At runtime, when the state of the parent form changes, the server is re-queried to determine the appropriate data to display in the linked controls.

In the Designer, a Link clause is generated automatically when the child control is added to the form. You can build your own link clause by selecting columns in the Expression Builder.

Example

  orders.orderid = orderdetails.orderid 

See also

Where Clause

Using child forms in the chapter on programming forms in the Programmer's Guide

Link Dialog   Top of page

The name of a form that SilverStream displays when the user clicks the Insert Link toolbar button in the HTML Edit Control.

Usage

Applies to AgcHTMLEditControl.

SilverStream displays the form you specify by calling the showFormDialog() method. When the user closes the form, the form must call the closeDialog() method. The argument for closeDialog() specifies the URL to be used in the A tag in the HTML Edit Control. The URL can be absolute, or it can be a relative URL for a page in the current SilverStream database.

If you don't specify a form in Link Dialog, the HTML Edit Control displays a default dialog for selecting a link target.

URLs for pages on the SilverStream server

The objects in a SilverStream database are in subdirectories below the SilverStream directory. To link to a page in the current database, you don't need to specify the subdirectories; specify only the file name:

  filename.ext 

To link to a page in the SilverMaster database or another database on the same server, specify an absolute URL; include the path to the Pages directory:

  http://hostname/Otherdatabase/SilverStream/Pages/filename.ext 

Context base

The default context base for relative URLs is the "current" database, which is the database containing the form that has the HTML Edit Control. For example, suppose that frmMain contains an HTML Edit Control and resides in MyDatabase; a relative URL passed by the closeDialog() method is relative to http://hostname/MyDatabase/.

You can change the base for relative URLs within the HTML Edit Control with the setContextBase() method. The HTML created in the HTML Edit Control is application data and can be used in other contexts. You might change context base if the HTML will ultimately be delivered in some other environment, such as from a servlet in some other location.

Example

Suppose that the form frmMain includes an HTML Edit Control. For the control's Link Dialog property, you specify frmLinkPicker, which is in the same database as frmMain. The field fldLinkTarget on frmLinkPicker holds the URL the user selected. In the actionPerformed event for the OK button, this code calls closeDialog() with the URL.

  closeDialog( fldLinkTarget.getText() ); 

See also

Image Dialog, Raw HTML Dialog, Toolbar

AgcHTMLEditControl.setContextBase()

Load Choices   Top of page

Specifies how to load list items for the control.

Usage

Applies to AgcChoice, AgcComboBox, AgcList, AgcTreeControl, AgcJComboBox, AgcJList.

Choices are:

For AgcTreeControl, you can only specify one level of data in the Property Inspector. To specify a multilevel hierarchy, write code in the formLoaded event.

See also

Choices, Display Value, Distinct, Load Choices, Limit Rows, Maximum Rows, Storage Value, Values

Load Data   Top of page

Specifies whether the AgcData control loads data from a database table or from specifications in a data source business object.

Usage

Applies to AgcData.

Values are From Table and From Business Object.

From Table loads data directly from the database. When you select this option, you can then specify the table and expressions for the column data to be retrieved in the Table and Column Expressions properties. You can further qualify the data that is retrieved with the Where Clause and Order By properties.

When you select From Business Object, you can specify a data source triggered business object that you have defined.

See also

Business Object Name, Column Expressions, Order By, Table, Where Clause

Chapter on data source business objects in the Programmer's Guide; AgiDataSource DSO example in Application Techniques

Major Tick Spacing   Top of page

Specifies the numeric interval between major tick marks on the slider control.

Usage

Applies to AgcJSlider.

Tick marks on the slider give the user feedback for the current value of the slider's pointer. The slider can display major tick marks (longer lines) and minor tick marks (shorter lines). When labels are turned on, they label the major tick marks. If you display labels, make sure the Major Tick Spacing interval is big enough so the labels don't overlap.

When Snap to Ticks is turned on, the slider's pointer jumps to the closest major or minor tick mark, whether or not tick marks are displayed.

To see tick marks, turn on Show Ticks.

See also

Minor Tick Spacing, Show Labels, Show Ticks, Snap To Ticks

JSlider.getMajorTickSpacing(), JSlider.setMajorTickSpacing()

Max Length   Top of page

Specifies the maximum number of characters allowed in a text input field.

Usage

Applies to AgcTextField, AgcJTextField.

If the user enters too many characters and tries to leave the field, SilverStream displays a message telling the user the limit and returns focus to the field. The user cannot leave the field until the input is within the length limits.

If you don't want SilverStream to display an error message, disable validation error messages by clearing the Show Validation Errors check box (under the Data heading on the Form page in the Property Inspector). This suppresses error messages for all controls on the form.

Example

If you disable messages, you can write code for the control's validationFailed event to display your own message. This example adds additional text to the message SilverStream would have displayed.

  agDialog.showMessage("Bad input! " + evt.getMessage()); 

See also

Min Length, Show Validation Errors

getMaxLength(), setMaxLength()

Forms and data validation in the Form Basics chapter of the Programmer's Guide

Maximum Rows   Top of page

Specifies the upper limit for the number of rows retrieved when Limit Rows is true.

Usage

Applies to AgcChoice, AgcComboBox, AgcData, AgcList, AgcTreeControl, AgcViewDownloadable, AgfForm, AgcJComboBox, AgcJList.

Maximum Rows takes effect when Limit Rows is true.

If Maximum Rows is 0, all rows are retrieved. Specifying 0 is the same as leaving Limit Rows unchecked.

For AgfForm, the limit applies to the number of rows retrieved by the AgData control. For the various list and tree controls, the limit applies when Load Choices is From Table. It affects the number of items retrieved for the list.

See also

Distinct, Load Choices, Limit Rows

Max Value   Top of page

Specifies the maximum value for the up arrow in a spinner control.

Usage

Applies to AgcIntegerSpinnerField, AgcJIntegerSpinnerField.

The user can also type a value in the spinner's input field. This value is not limited by Max Value. To limit the value that the user can type in spinner controls and numeric input fields, specify validation rules for the control.

See also

Min Value, Validation Rules

AgcIntegerSpinnerField.getMaxValue(), AgcIntegerSpinnerField.setMaxValue()

Maximum Value   Top of page

Specifies the high value for the slider's range.

Usage

Applies to AgcJSlider

The position of the high value on the slider depends on the Inverted and Orientation properties.

See also

Minimum Value, Initial Value, Inverted, Orientation

Min Length   Top of page

Specifies the minimum number of characters allowed in a text input field.

Usage

Applies to AgcTextField, AgcJTextField.

If the user enters too few characters, SilverStream displays a message telling the user the limit and returns focus to the field. The user cannot leave the field until the input is within the length limits.

If you don't want SilverStream to display an error message, disable validation error messages by clearing the Show Validation Errors check box (under the Data heading on the Form page in the Property Inspector). This suppresses error messages for all controls. To display your own message, write code for the validationFailed event.

See also

Max Length (validationFailed event example), Show Validation Errors

getMinLength(), setMinLength()

Forms and data validation in the Form Basics chapter of the Programmer's Guide

Min Value   Top of page

Specifies the minimum value for the down arrow in a spinner control.

Usage

Applies to AgcIntegerSpinnerField, AgcJIntegerSpinnerField.

The user can also type a value in the spinner's input field. This value is not limited by Min Value. To limit the value that the user can type in spinner controls and numeric input fields, specify validation rules for the control.

See also

Max Value, Validation Rules

AgcIntegerSpinnerField.getMinValue(), AgcIntegerSpinnerField.setMinValue()

Minimum Value   Top of page

Specifies the low value for the slider's range.

Usage

Applies to AgcJSlider

The position of the low value on the slider depends on the Inverted and Orientation properties.

See also

Maximum Value, Initial Value, Inverted, Orientation

Minor Tick Spacing   Top of page

Specifies the numeric interval between minor tick marks on the slider control.

Usage

Applies to AgcJSlider.

Where a minor and major tick mark coincide, a major tick mark is displayed.

Tick marks on the slider give the user feedback for the current value of the slider's pointer. For more information, see Major Tick Spacing.

See also

Major Tick Spacing, Show Labels, Show Ticks, Snap To Ticks

JSlider.getMinorTickSpacing(), JSlider.setMinorTickSpacing()

Name   Top of page

Specifies the name for the control when programming.

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcChoice, AgcComboBox, AgcData, AgcFileAttachment, AgcHTMLEditControl, AgcImage, AgcIntegerSpinnerField, AgcLabel, AgcList, AgcRectangle, AgcTabControl, AgcTextArea, AgcTextField, AgcTimer, AgcTreeControl, AgcView, AgcViewDownloadable, AgcJButton, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJLabel, AgcJList, AgcJRadioButton, AgcJSlider, AgcJTabbedPane, AgcJTextArea, AgcJTextField.

The name you specify is used for the variable that holds a reference to the control. When you change the name of a control and compile the form, the name is changed throughout your code and generated code.

When a control is created in a Designer, it is assigned a default name corresponding to that control type. For example, all Label controls (AgcLabel) are named Labeln by default, where n is an integer that begins at 1 and is incremented by one for each instance of the control created. If three instances of a Label control are placed on a form, the controls are created with the default names Label1, Label2, and Label3.

When you change the name to a meaningful identifier for your application, it must follow these Java rules:

As part of your application development guidelines, you might want to adopt standard prefixes that identify the type of each control. See the General Reference for suggested guidelines.

See also

Component.getName()

Normal Image   Top of page

Specifies an image to display when the button is in its normal state.

Usage

Applies to AgcJButton.

The normal state means the button is not pressed or disabled and the mouse is not over the button. This image is also used as the pressed and disabled image if the other image properties have no value.

For information on URLs and cropping specifications for images, see the Image property.

See also

Disabled Image, Pressed Image, Rollover Image

getIcon(), setIcon()

Order By   Top of page

A String value that represents a SQL Order By clause. The SQL Order By clause specifies the order in which the selected records are returned from the database.

Usage

Applies to AgcChoice, AgcComboBox, AgcData, AgcList, AgcTreeControl, AgfForm, AgcJComboBox, AgcJList.

To specify an Order By clause, open the Expression Builder, select a column or specify an expression that uses one or more columns, and choose the Ascending or Descending button.

See also

Where Clause

Orientation   Top of page

Usage

Applies to AgcJSlider

Specifies whether the slider track is horizontal or vertical.

Usage

Applies to AgcJSlider.

When you change the orientation, you will probably need to change the slider's size and position.

To reverse the location of the high and low values, use the Inverted property.

See also

Inverted

Pane Captions   Top of page

Specifies text to display on the tab of a pane.

Usage

Applies to AgcTabControl, AgcJTabbedPane.

The number of captions you can specify correspond to the number of panes specified in the Panes property. For each pane, you can specify a text caption, an image, or both.

See also

Inactive Tab Color, Pane Images, Panes

AgcTabControl.getPaneName(), AgcTabControl.setPaneName(), JTabbedPane.getTitleAt(), JTabbedPane.setTitleAt()

Pane Images   Top of page

Specifies an image to display on the tab of a pane.

Usage

Applies to AgcTabControl, AgcJTabbedPane.

The number of captions and images you can specify correspond to the number of panes specified in the Panes property. For each pane, you can specify a text caption, an image, or both.

The size of the pane's tab will be adjusted to fit the image you specify, so the image shouldn't be very large. To use part of a larger image, specify the pixel coordinates of the portion of the image you want to use. The syntax is:

  imageurl x y width height  

For more information, see the section on cropping a larger image in the Form Designer section of the Tools Guide.

For information on ways to specify image files, see the Image property.

See also

Background Color, Image, Inactive Tab Color, Pane Captions, Panes

AgcTabControl.getPaneImage(), AgcTabControl.setPaneImage(), JTabbedPane.getIconAt(), JTabbedPane.setIconAt()

Panes   Top of page

Specifies the number of panes for the control.

Usage

Applies to AgcTabControl, AgcJTabbedPane.

For tab controls, the default is three.

See also

AgcTabControl.getPaneCount(), AgcTabControl.setPaneCount(), JTabbedPane.getTabCount(), JTabbedPane.addTab(), JTabbedPane.insertTab()

Parameters   Top of page

A named parameter associated with a subform. Using parameters is a technique for passing information between a parent form and a child form when the child form is displayed with the showPage() method.

Usage

Applies to subforms.

Parameters can no longer be added in the Designer. For information on using parameters as well as other techniques for communicating between parent and child forms, read about using child forms in the Programming Forms chapter of the Programmer's Guide.

showPage() in the PVHelperBrowser class

Pressed Image   Top of page

Specifies an image to display when the button is pressed.

Usage

Applies to AgcJButton.

If you don't specify a pressed image, the button displays the normal image when it is pressed.

For information on URLs and cropping specifications for images, see the Image property.

See also

Disabled Image, Normal Image, Rollover Image

getPressedIcon(), setPressedIcon()

Radio Button Group   Top of page

Specifies the name of the Radio Button's button group.

Usage

Applies to AgcButtonImage, AgcButtonRadio, AgcJRadioButton.

Radio Button controls are used to allow a user to select a single choice from multiple values. When the user selects one button in the group, a previously selected button is deselected. The button group determines the set of controls that work together as a selection unit.

The group name is an arbitrary string. You must assign the same string to all the buttons that should work together as a group. The default name for AgcButtonImage and AgcButtonRadio controls is DefaultButtonGroup. The default name for AgcJRadioButton is DefaultJButtonGroup.

Raw HTML Dialog   Top of page

The name of a form that SilverStream displays when the user clicks the Raw HTML toolbar button (the button that shows a pair of angle brackets) in the HTML Edit Control.

Usage

Applies to AgcHTMLEditControl.

SilverStream displays the form you specify by calling the showFormDialog() method. When the user closes the form, the form must call the closeDialog() method. The argument for closeDialog() specifies the HTML to be inserted in the HTML Edit Control.

If you don't specify a form in Raw HTML Dialog, the HTML Edit Control displays a default dialog for entering a line of HTML.

Example

Suppose that the form frmMain includes an HTML Edit Control. For the control's Raw HTML Dialog property, you specify frmEnterRawHTML, which is in the same database as frmMain. The field fldRawHTML on frmEnterRawHTML holds the data the user entered. In the actionPerformed event for the OK button, this code calls closeDialog() with the raw HTML as an argument.

  closeDialog( fldRawHTML.getText() ); 

See also

Image Dialog, Link Dialog, Toolbar

Rollover Image   Top of page

Specifies an image to display when mouse is over the button.

Usage

Applies to AgcJButton.

If you don't specify a rollover image, the button displays the normal image when the mouse if over the button.

For information on URLs and cropping specifications for images, see the Image property.

See also

Disabled Image, Normal Image, Pressed Image

getRolloverIcon(), setRolloverIcon()

Shadow Color   Top of page

Sets the color for the shadow effect on the control.

Usage

Applies to AgcLabel, AgcTabControl, AgcJLabel, AgcJTabbedPane.

For the Label control, the Shadow Color is only used when the Text Style is Embossed or Drop Shadow.

See also

Background Color, Dark Shadow Color, Highlight Color, Inactive Tab Color, Text Color

AgcTabControl.getShadowColor(), AgcTabControl.setShadowColor()

Show Labels   Top of page

Specifies whether labels mark the intervals on the slider.

Usage

Applies to AgcJSlider.

The labels are the numeric values of the major tick marks. You can display labels, tick marks, or both.

See also

Major Tick Spacing, Minor Tick Spacing, Show Ticks, Snap To Ticks

JSlider.createStandardLabels(), JSlider.getLabelTable(), JSlider.setLabelTable()

Show Ticks   Top of page

Specifies whether lines mark the intervals on the slider.

Usage

Applies to AgcJSlider.

Show Ticks controls the display of both major and minor tick marks. If the Tick Spacing value for either is 0, those tick marks aren't displayed.

See also

Major Tick Spacing, Minor Tick Spacing, Show Ticks, Snap To Ticks

JSlider.getPaintTicks(), JSlider.setPaintTicks()

Show Validation Errors   Top of page

Specifies whether the form displays a validation failure message in a dialog box when a control fails validation.

Usage

Applies to AgfForm.

By default, the Show Validation Errors property is set to true. The form can be prevented from displaying any validation failure messages by unchecking the Show Validation Errors check box on the form property sheet. When the Show Validation Errors property is checked, then validation failure messages are displayed in a message box. To handle validation failures some other way (for example, in the form validationFailed event) uncheck this box to prevent the dialog from showing.

A control can fail validation because user input didn't meet the criteria of a validation rule, it violated limits set by some properties, or code in the validationTest event failed the data by throwing an exception.

See also

Max Length, Min Length

Snap To Ticks   Top of page

Specifies whether the slider's pointer snaps to a tick mark when the user moves it.

Usage

Applies to AgcJSlider.

See also

Major Tick Spacing, Minor Tick Spacing, Show Ticks

JSlider.getSnapToTicks(), JSlider.setSnapToTicks()

Start Automatically   Top of page

Specifies whether the timer control starts automatically when the application starts.

Usage

Applies to AgcTimer.

If Start Automatically is set to false, call the startTimer() method to start the Timer.

See also

Interval

AgcTimer.startTimer(), AgcTimer.stopTimer()

Storage Value   Top of page

Specifies the name of the database column which contains the internal values of the list items.

Usage

Applies to AgcChoice, AgcComboBox, AgcList, AgcTreeControl, AgcJComboBox, AgcJList.

To load a list with data from a database table, set the Load Choices property to From Table. Then specify a value for the Table property and Display Value properties. You can also specify the Storage Value property if you want a bound control to store a value in the database that is different from the displayed value.

The Display value specifies the text that is shown to the user in the list. The Storage value is used internally to determine which list value becomes selected, and also what value to store in the database when the user chooses from the list. It is not normally shown to the user.

For example, a database may store region data by number, and the region list is stored in a table containing a region number column (e.g. 1, 2, etc) and a description column (e.g. Northeast, Midwest, etc). The Display value property could be set to the description column, and the Storage value property to the number column. If a record were then displayed in a form, and the record's region column contained the number 2, the control would look for this region number from its list of internal storage values to determine which list choice to display. Since the storage value 2 corresponds to the display value Midwest, then Midwest will be displayed in the control. Then, if the user were to select the Northeast item from the list, the control would determine that the display value Northeast corresponds to the storage value 1, and so it would set the record's region value to 1.

See also

Load Choices, Table, Display Value

Table   Top of page

Specifies the name of the database table from which the control loads its list data.

Usage

Applies to AgcChoice, AgcComboBox, AtcData, AgcList, AgcTreeControl, AgcJComboBox, AgcJList.

For a form, you can specify or change the table associated with the form using the Relational Data Palette, rather than the Property Inspector.

See also

Load Choices, Display Value, Order By, Storage Value, Where Clause

Text Color   Top of page

Sets the color for the control's text.

Usage

Applies to AgcIntegerSpinnerField, AgcLabel, AgcRectangle, AgcTextArea, AgcTextField, AgcJIntegerSpinnerField, AgcJLabel, AgcJTextArea, AgcJTextField.

See also

Font Name, Font Size, Font Style, Highlight Color, Shadow Color, Text Style

Component.setForeground()

Text Style   Top of page

Specifies the style for the Label's text.

Usage

Applies to AgcLabel, AgcJLabel.

The Text Style supports these text styles: Normal, Drop Shadow, and Embossed. When the style is Embossed, the control uses a Highlight Color and a Shadow Color. When the style is Drop Shadow, the control uses a Shadow Color.

See also

Caption Expression, Caption Text, Highlight Color, Shadow Color, Text Color

AgcLabel.setTextStyle(), AgcLabel.getTextStyle()

Tool Tip   Top of page

Specifies a single line of text that is displayed when the user moves the mouse over the control.

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcChoice, AgcComboBox, AgcHTMLEditControl, AgcImage, AgcIntegerSpinnerField, AgcLabel, AgcList, AgcRectangle, AgcTabControl, AgcTextArea, AgcTextField, AgcTreeControl, AgcView, AgcJButton, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJLabel, AgcJList, AgcJRadioButton, AgcJSlider, AgcJTabbedPane, AgcJTextArea, AgcJTextField.

See also

AgiControl.setToolTipText(), AgiControl.getToolTipText()

Toolbar   Top of page

Specifies whether the HTML Edit Control displays the toolbar at runtime.

Usage

Applies to AgcHTMLEditControl.

See also

Image Dialog, Link Dialog, Raw HTML Dialog

Top   Top of page

Specifies the location of the top of the control in pixels, relative to the control's container (e.g., the form control.)

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcChoice, AgcComboBox, AgcHTMLEditControl, AgcImage, AgcIntegerSpinnerField, AgcLabel, AgcList, AgcRectangle, AgcTabControl, AgcTextArea, AgcTextField, AgcTreeControl, AgcView, AgcViewDownloadable, AgcJButton, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJLabel, AgcJList, AgcJRadioButton, AgcJSlider, AgcJTabbedPane, AgcJTextArea, AgcJTextField.

See also

Left, Width, Height

Component.getLocation(), Component.setLocation()

Transparent   Top of page

Specifies whether the control is transparent.

Usage

Applies to AgcButtonImage, AgcImage, AgcLabel, AgcRectangle, AgfForm, AgcJButton, AgcJLabel.

When Transparent is true, then the control is transparent and objects behind the control show through. The background color does not fill the control.

See also

Background Color, Color

JComponent.isOpaque(), JComponent.setOpaque()

Unchecked Value   Top of page

Specifies the value that gets written to the database when the user unchecks the Check Box.

Usage

Applies to AgcButtonCheck, AgcJCheckBox.

When the Check Box control is bound to a database column (specified by the Database Column property), the Unchecked Value property specifies the value written to the bound database column when the Check Box is not checked. If an Unchecked Value is not specified, then the value "false" is written to the database when the Check Box isn't checked.

See also

Checked Value, Database Column

Up Image   Top of page

Specifies an image to display when the button's pressed state is false, that is, the button is not pressed.

Usage

Applies to AgcButtonImage.

For information on URLs and cropping specifications for images, see the Image property.

See also

Down Image

AgcButtonRaw.setUpImage(), AgcButtonRaw.getUpImage()

Validation Rules   Top of page

One or more expressions that result in a true or false value, used to ensure that the user enters valid data.

Usage

Applies to AgcIntegerSpinnerField, AgcTextField, AgcTextArea, AgcJIntegerSpinnerField, AgcJTextField, AgcJTextArea, AgcJEditorPane.

When data fails a validation rule, SilverStream displays a message and fires the validationFailed event.

The rules you specify are listed in on the property sheet, each in an input field. Click Add new rule to get a new input field for another rule. Beside each rule, click the ellipses button to display the Expression Builder for that rule.

The Expression Builder provides tools for specifying validation rules. In the left pane, you see:

At the bottom of the Validation Rules Expression Builder, you can specify a message to display when the user's data fails the Validation Rule (that is, the expression results in false).

To respond to the error with more than SilverStream's message box, write code for the validationFailed event. You can correct the value or force focus back to the control.

In addition to validation rules, you can validate data with code in the validationTest event. You can also set properties that check the length and value in an input field.

Example

This rule specifies that the user's value must be the same as the value in the fldStateID input field.

  _newValue = fldStateID 

This rule specifies that the new value must be greater than the last value entered in the field.

  _newValue > _lastValue 

This rule specifies that the value in the date field must be greater than today's date.

  _newValue > today() 

This rule specifies that the input must begin with "http:" or "HTTP:".

  lower(_newValue) startsWith "http:" 

See also

Max Length, Max Value, Min Length, Min Value

Values   Top of page

Specifies a list of values that map to the static choices displayed to the user.

Usage

Applies to AgcChoice, AgcComboBox, AgcList, AgcTreeControl, AgcJComboBox, AgcJList.

To specify a list for the Values property, set the Load Choices property to Statically.

To enter a list of values, display the Edit Property dialog box and enter each value on a separate line. The number of lines should be the same as the number of items in the list for the Choices property.

The Values property provides a convenient way to work with the data when you want to show the user a "readable" value, but internally you want to work with IDs or numbers for those values. For example, to allow the user to choose from a number of different products, you could specify product names in the Choices property and product IDs in the Values property.

The Values property serves the same purpose as the Storage Values property when the list is loaded from a database table.

See also

Choices, Load Choices, Storage Value

e.g., AgcJList.getItemAt(), AgcJList.getItemValue(), AgcJList.insertItemAt()

Vertical Alignment   Top of page

The vertical position of the image and text within the bounds of the label control.

Usage

Applies to AgcJButton, AgcJLabel.

The Horizontal Alignment property positions the image and text as a unit. To change the relative positions of the image and text, use the Horizontal Text Position property.

See also

Horizontal Text Position, Vertical Alignment, Vertical Text Position

Vertical Scrollbar   Top of page

Specifies whether the control displays a vertical scrollbar at runtime.

Usage

Applies to AgcTextArea, AgcJTextArea.

See also

Horizontal Scrollbar

Vertical Text Position   Top of page

Specifies the vertical position of the text in the label control relative to the image.

Usage

Applies to AgcJButton, AgcJLabel.

Values are Above image, Center, Below image. When both Vertical and Horizontal Text Position are Center, the text displays in front of the image.

See also

Horizontal Alignment, Horizontal Text Position, Vertical Alignment

Visible   Top of page

Specifies whether this control is initially visible on the form at runtime.

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcChoice, AgcComboBox, AgcHTMLEditControl, AgcImage, AgcIntegerSpinnerField, AgcLabel, AgcList, AgcRectangle, AgcTabControl, AgcTextArea, AgcTextField, AgcTreeControl, AgcView, AgcViewDownloadable, AgcJButton, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJLabel, AgcJList, AgcJRadioButton, AgcJSlider, AgcJTabbedPane, AgcJTextArea, AgcJTextField.

See also

Enabled

Component.isVisible(), Component.setVisible()

Where Clause   Top of page

A String expression that represents a SQL Where Clause. It can be set through the Property Inspector. A Where clause can also be specified using the query() method. If a Where Clause property is specified in the Property Inspector and then the query() method is also called, the Where clause for query() is ANDed to the Where Clause property to create a single SQL Where clause.

A SQL Where Clause specifies criteria or conditions that must be met in order for a record to be included in a dataset. (SilverStream appends the Where keyword to the SQL String so it is not necessary to enter it in the Property Inspector.)

Usage

Applies to AgcChoice, AgcComboBox, AgcData, AgcList, AgcTreeControl, AgfForm, AgcJComboBox, AgcJList.

For the Where Clause property, specify columns using tablename.columnname syntax. Do not specify the keyword Where; SilverStream adds it automatically.

Specifying a Where clause with the AgfForm class can sometimes improve performance. For example, if a Where clause is specified that only references fields in the dataset from which the choices are being loaded, then the restriction of choices is fixed. This allows the SilverStream server to compute the list before it downloads the page that contains the control, thus speeding up the display of data.

If the Where clause references fields in the containing form's dataset or values of other controls on the form, then the set of choices is not fixed; it can change based on user actions. For example, the form might contain a check box specifying whether the user wants to choose from Active or Inactive customers. In this case, the Where clause is called a "Link Clause" because it allows a link between the state of the form and the set of choices in the list control. Whenever the state of the form changes, the control automatically re-queries the server to determine the appropriate set of choices to display.

Note that SilverStream does not perform any SQL syntax checking. If the SQL is not syntactically correct, a runtime error is generated. Since some database management systems are case-sensitive, the table and field references should exactly match the names used in the database.

With the List, Tree, Choice, or ComboBox controls, the Load Choices property must be set to From Table to load data from a dataset.

Example

  employees.empid > 0 
employees.deptid=200

See also

Link Clause, Load Choices, Load Data, Order By

Width   Top of page

Specifies the control's width in pixels.

Usage

Applies to AgcButtonCheck, AgcButtonImage, AgcButtonRadio, AgcButtonText, AgcChoice, AgcComboBox, AgcHTMLEditControl, AgcImage, AgcIntegerSpinnerField, AgcLabel, AgcList, AgcRectangle, AgcTabControl, AgcTextArea, AgcTextField, AgcTreeControl, AgcView, AgcViewDownloadable, AgfForm, AgcJButton, AgcJCheckBox, AgcJComboBox, AgcJIntegerSpinnerField, AgcJLabel, AgcJList, AgcJRadioButton, AgcJSlider, AgcJTabbedPane, AgcJTextArea, AgcJTextField.

Note that the control's size (Width and Height) is represented in the database relative to the system's font sizes, ensuring that the control is displayed properly on a system whose default fonts differ from the default fonts on which the control was designed.

See also

Left, Top, Width

Methods of JComponent or Component: getBounds(), getHeight(), getSize(), setBounds(), setSize()

Word Wrap   Top of page

Specifies whether to display the label text on multiple lines if the control is too narrow to display the text on a single line.

Usage

Applies to AgcLabel, AgcJLabel.

When Word Wrap is true and when the text is too long for the control, the text displays on multiple lines. If Word Wrap is false, the text is truncated. If the height of the control is too small for the number of lines, the characters are clipped.

See also

getWordWrap(), setWordWrap()






Copyright © 2000, SilverStream Software, Inc. All rights reserved.