Methods                                                                                                       Object

 

Methods change the appearance or settings of an object. Each object has certain methods that can be used. Check the documentation for the Object to find which ones of these methods applies to it.

 

Add Itemtext, indexNo[,NODISPLAY]

Add ItemText to list at indexNo. NODISPLAY delays updating List Objects until complete. For Grid objects, there are no arguments: a new row is added to the bottom of the table.

Clear

Clear a listthe object. If the object is a form, all fields are set to empty. (""). If it is a Grid, all rows are deleted.

Count

Returns the number of objects for a Form object.

Hide

Hide the object

ID

Get the object's internal ID number (integer), Useful for API calls.

Index

Object's position on form. First position is 0. If the form has a title, it is Index 0.

ItemNo item[, index]

Add item to list at position indexNo. If indexNo is 1, add to beginning of list. If no indexNo supplied, add item to end of list.

Itemtext IndexNo

Get item in a list

Max int

Get or set maximum value of scrollbar

MaxChars int

Get or set maximum characters

Min int

Get or set minimum value of scrollbar

NoItems

Get number of items in a list

PageSize int

Get or set page size value of scrollbar

Redraw

Refresh the object

Remove indexNo

Remove row indexNo from listobject

Selected indexNo

Get or set selection

SetFocus

Set focus to object

Show

Show the object

Status

Used by Checkbox and Pushbutton

Text

Get or set the text or label

Value CurValue

Get or set current value of scrollbar

 

Example

MyField.text="Reg Llama" 'set text of a field

MyPopupList.add "Brixton" 'add a name to a popup list

MyCheckbox.setFocus 'set the focus to a field

Msgbox MyOtherField.text 'output the value of a field

MyCheckbox.status=nsbChecked 'set checkbox