ActiveX Control Reference
 
ActiveX Control Reference
This following topics describe the ActiveX controls for PSQL and list the properties, methods, and events of each type of control:
VAccess Data Source
VACheck
VACombo
VACommand
VAHScroll and VAVScroll
VAList
VAOption
VAText
VAccess Data Source
Description
The VAccess control is the data source control. It provides database communication with the source code of an application and data transfer to the other eight bound controls and to third-party controls.
Remarks
The VAccess control is visible at design time as an icon, but is not visible at run time.
Each VAccess control references one table in a database at a time. The control is connected to a database in one of two ways:
by setting the DdfPath property of the control to the location of the data dictionary files (FILE.DDF, FIELD.DDF, and INDEX.DDF) which define the database. The VAccess control requires DDF files for its database definition at design time. The record source for the control is specified by setting the TableName property to the name of one of the tables in the data dictionary. The physical operating system path to the database file is specified by the Location property, which defaults to the table location defined in the DDF when TableName is chosen..
by setting the HostAddress property of the control to the name of a machine and the DatabaseName property to a database name on that machine. Choose the table using the TableName property
The OwnerName property allows you to specify an owner name if one is required for opening the table.
Record navigation properties and methods and field access properties provide record data in code. The data source can also be bound to the other controls provided or to third-party data controls that operate as bound controls in Visual Basic.
Custom Properties, Events, and Methods
Custom properties, events, and methods for this control are listed in the following tables in alphabetical order. For lists of custom properties, methods, and events by category, see the chapter Properties, Methods, and Events By Category.
The lists of properties does not include stock properties such as (About), (Custom), (Name), Index, Left, Tag, and Top.
Table 7 VAccess Custom Properties
AutoDialog
DataLength
IndexNumber
RowPosition
AutoLogon
DdfKeyUseIndexDDFOnly
Join
Rows
AutoMode
DdfPath
Location
Selected Fields
AutoOpen
DdfTransactionMode
MaxBufferSize
SelectedRecords
Buffer
ExtendedOps
OemString
SessionID
CacheRejectMax
FieldList
OpenMode
Status
CacheRows
Fields
OwnerName
TableName
CancelDialog
FieldValue
PageSize
TimeOutVal
Column
FileVersion
Percentage
TotalRecords
ColumnName
FireEvents
Port
VADebugMode
Columns
HostAddress
Position
 
CompressData
HostConnect
RefreshLocations
 
DatabaseName
IncludeCurrent
Row
 
Table 8 VAccess Custom Methods 
AboutBox
DdfGetFieldComments
GetLessOrEqual
ShowSelectedFieldsDlg
Btrv
DdfModifyLocation
GetNext
ShowSelectedRecordsDlg
Clear
DdfModifyTableName
GetNextExtended
Stat
Close
DdfSetOwner
GetPrevious
StatusDialog
Create
DdfTestOwnerName
GetPreviousExtended
StepFirst
DdfAddIndex
Delete
GetTableList
StepLast
DdfAddTable
FormatFieldValue
GetTotalSegments
StepNext
DdfAddTableName
GetDirect
Init
StepNextExtended
DdfClearFields
GetEqual
Insert
StepPrevious
DdfClearIndexes
GetFileFlag
OpCode
StepPreviousExtended
DdfCreateDictionary
GetFirst
Open
Transaction
DdfCreateTable
GetGreater
Refresh
Unlock
DdfDropIndex
GetGreaterOrEqual
RowColumnValue
Update
DdfDropIndexMaintain
GetLast
SetFileFlag
 
DdfDropTable
GetLess
SetOwner
 
Table 9 VAccess Custom Events
CommError
Logon
Reposition
GotData
OnRemote
Validate
VACheck
Description
The VACheck control displays the state of a boolean (True/False) field value.
Remarks
The data source for a VACheck Control is determined by the setting of the VAccessName property.
The field source is bound by setting the VAFieldName property to the name of a boolean (Logical or Bit type) field in the data source.
True and False storage values for the field, other than 1 and 0, can be defined with the VAValueTrue and VAValueFalse properties of the control.
Custom Properties and Methods
Custom properties and a custom method for this control are listed in the following tables:
 
Table 10 VACheck Custom Properties
VAccessName
VAFieldName
VADataType
VAOffset
VADebugMode
VASize
VADecimal
 
Table 11 VACheck Custom Method
AboutBox
VACombo
Description
The VACombo combines elements of a text box and a list box. The user may either enter a value or select from a list of options.
Remarks
The VACombo can operate in three distinct modes: field-bound, record list, and index list.
To use this control as a field-bound data control, you assign the VAFieldName property the name of one of the fields in the file specified in the VAccessName property. You can use the AddItem method to populate a field-bound combo box with a list of valid selections for the field.
To use this control in record list mode, set the VARecordList property as True.
Note When using the VARecordList functionality of the VACombo (i.e. VARecordList = True), only one field name may be specified in the SelectedFields property, and that field must be the field indexed in the active key (or one of the fields indexed in a segmented key).
Specifying multiple field names in SelectedFields is not supported. This would result in only the first specified field appearing in the VACombo control.
Specifying a field that is not indexed is not supported. This would result in no data appearing in the VACombo control.
To use the control to populate the list with the indexes defined for the associated file and allow the user to select the current index at run time, set the VAFieldName property to [Index List].
Custom Properties and Methods
Custom properties and methods for this control are listed in the following tables:
Table 12 VACombo Custom Properties
IntegralHeight
VAccessName
VADecimal
VAOffset
List
VADataType
VAFieldName
VARecordList
VADebugMode
VAFormat
VASize
Table 13 VACombo Custom Methods
AboutBox
Clear
RemoveItem
AddItem
Refresh
 
VACommand
Description
You can use the VACommand to execute common operations on the data source file when the button is clicked at run time.
Remarks
The VACommand is bound to a data source by setting the VAccessName property at design time or run time.
The VAOperation property determines what operation will be performed when the button is clicked at run time.
If the VAOperation property specifies a record retrieval operation, you can use the VALockBias property to lock the record when it is retrieved. The VALockBias property has no effect on Open, Close, Insert, and Update operations.
The VAErrorDialog property enables or disables the display of a text message to the user if the operation performed by the control returns an error.
Note The Click event executes the code in the VACommand_Click subroutine before the PSQL operation specified in the VAOperation property is executed.
Custom Properties
Custom properties for this control are listed in the following table:
 
Table 14 VACommand Custom Properties
VAccessName
VALockBias
VADebugMode
VAOperation
VAErrorDialog
 
VAHScroll and VAVScroll
Description
The VAHScroll and VAVScroll controls navigate through the data source along the currently selected index path.
Remarks
The VAHScroll and VAVScroll are bound to a VAccess control via the VAccessName property.
The positioning of the thumb scroll will reflect the relative positioning of the current record along the current index path as determined by the PSQL FindPercentage operation, and dragging the thumb scroll will result in the appropriate record being retrieved by a PSQL GetByPercentage operation.
Custom Properties
Custom properties for this control are listed in the following table:
Table 15 VAHScroll and VAVScroll Custom Properties
VAccessName
VADebugMode
Value
VAList
Description
The VAList control allows a user to select an item from a list.
Remarks
The data source for the VAList control is determined by the value of the VAccessName property.
The list box control can operate in two distinct modes, determined by the setting of the VARecordList property.
If the VARecordList property is False, the list box acts as a field-bound data control. Assign the field data source for the list box by setting the VAFieldName property to the name of one of the fields in the data source. Use the AddItem method to populate a field-bound list box with a list of valid arguments for the field.
If the VARecordList property is True, the list box acts as a multi-column record list for the associated data source. Set the value of the VAFieldName property to the list of fields to be displayed in the list, separated by semicolons. (If you leave the field blank, it will default to all fields.) You may also set formats for each field by specifying a list of format strings, separated by semicolons, in the VAFormat property. Control the horizontal spacing of the columns within the list box by setting the ColumnWidth property. Column widths are measured in pixels.
Custom Properties and Methods
Custom properties and methods for this control are listed in the following tables:
Table 16 VAList Custom Properties
ColumnWidth
VAccessName
VADecimal
VAOffset
List
VADataType
VAFieldName
VARecordList
VAAutoScroll
VADebugMode
VAFormat
VASize
Table 17 VAList Custom Methods
AboutBox
Clear
RemoveItem
AddItem
Refresh
 
VAOption
Description
The VAOption control displays the state of a boolean (True/False) field value.
Remarks
The data source for a VAOption Control is determined by the setting of the VAccessName property.
The field source is bound by setting the VAFieldName property to the name of a boolean (Logical or Bit type) field in the data source.
True and False storage values for the field can be defined with the VAValueTrue and VAValueFalse properties of the control.
Only one option button in a given parent window (on a form or in a group box) may be selected, or True, at any one time.
Custom Properties and Methods
Custom properties and methods for this control are listed in the following tables:
Table 18 VAOption Custom Properties
VAccessName
VADebugMode
VASize
VADataType
VAFieldName
VAValueFalse
VADecimal
VAOffset
VAValueTrue
Table 19 VAOption Custom Method
AboutBox
VAText
Description
The VAText control displays and allows a user to edit the value of a field.
Remarks
The data source for a VAText Control is determined by the setting of the VAccessName property.
The field source is bound by setting the VAFieldName property to the name of a field in the data source.
As with other bound controls, changes made in the text box are reflected in the data buffer in memory but are not written to the file until an update or insert operation is performed on the current record.
If the VASearch property of the text box is True, changes in the text box will cause a repositioning of the current record using the value of the text in the text box as the first segment of the current index. You may use a text box in search mode in conjunction with a VAList in record list mode to implement a record browser or lookup table.
Custom Properties and Methods
Properties and a method for this control are listed in the following tables:
Table 20 VAText Custom Properties
AutoScroll
VAccessName
VAFieldName
VASize
FocusSelText
VADataType
VAFormat
WantReturn
LockedMaxLength
VADebugMode
VAOffset
 
Uppercase
VADecimal
VASearch
 
Table 21 VAText Custom Method
AboutBox