DBDropList

(ODBC Manager Library)

Maintained only to provide backward compatibility with legacy applications. Do not use in new code.

Description: Populates a droplist using the results of an SQL query on a given database.
Format: \ODBCManager\DBDropList(    X1,  Y1,  X2,  Y2,  DSN,  UserName,  Password,  SQLQuery,  Title,  LocFocusID,  Init,  Var[,  DrawBevel,  AlignTitle,  AddInvalid,  InvalidText])
Returns: Numeric
Usage: Script Only.
Function Groups: Database and Data Source
Related to: AddConnection | BuildDelete | BuildInsert | BuildSelect | BuildUpdate | ConvertToDbDate | ConvertToDbTime | ConvertToDbTimeStamp | ConvertToVTSDate | ConvertToVTSTime | ConvertToVTSTimeStamp | CopyRecords | DBGridList | ErrMessage | ExecuteQuery | ExecuteQueryCachedFlushCache | FormatBatchQuery | GetConnList | ResultFormat | StatsWin | TableSynch | Transaction | TransactionCached
Parameters:  
X1
Required. Screen coordinates of the left side of drop list
Y1
Required. Screen coordinates of the top of list
X2
Required. Screen coordinates of the right side of the list
Y2
Required. Screen coordinates of the bottom of list
DSN
Required. DSN of the database to query
UserName
Required. The user name in the database for authentication.
Password
Required. The password in the database for authentication.
SQLQuery
Required. An SQL query that returns either one or two columns. The first column is used for droplist display,  the second (if it exists) provides the matching value for each entry in the list.
Title
Required. The title for the drop list
LocFocusID
Required. Numeric  expression from 0 to 32767 for the focus number of this graphic. If this value is 0, the droplist will display its current setting, but will not be able to be opened (i.e. its value cannot be changed) and will appear grayed out. The default value is 1.
Init
Required. Any expression for the initial value displayed in the field
Var
Required. A variable whose value will be set by this droplist
DrawBevel
Optional. If true (non-0) a bevel is drawn around the droplist. If false (0) no bevel is drawn. The default value is false
AlignTitle
Optional. If true (non-0) the title is included in the calculation for vertical alignment. If false(0) it is added to the droplist after it (and its bevel if one exists) has been vertically aligned. The default is true
AddInvalid
Required. If true an entry with an invalid value will be added at the top of list.
InvalidText
Required. Used with AddInvalid to provide the text to display for the item at the top of the list.
Comments: This module is a member of the ODBCManager Library, and must therefore be prefaced by \ODBCManager\, as shown in "Format" above.