Specifies the type of source for the values in a control. Available at design time and run time.
Syntax
Control.RowSourceType[ = nSource]
Settings
nSource
The settings for the RowSourceType property are:
Setting | Description |
0 | (Default) None. When the default value is used, fill the list at run time using the AddItem or AddListItem method. |
1 | Value. Populated by a comma-delimited list. |
2 | Alias. Use the ColumnCount property to select fields in the table. |
3 | SQL Statement. A SQL SELECT command that creates a cursor or a table. |
4 | Query (.qpr). Specify a file name with a .qpr extension. |
5 | Array. Set the columns property to display multiple dimensions. |
6 | Fields. A comma delimited list of fields. The fields may be prefaced by the table alias and a period. |
7 | Files. List is populated from the current directory. Specify file skeleton (such as *.dbf or *.txt) or mask in the RowSource property. |
8 | Structure. Fields from the table specified in RowSource.
Note that when RowSourceType is set to 8, if the RowSource property is empty the currently selected table is used as the source of the values in a ComboBox or ListBox control. Otherwise, the RowSource property specifies the alias of the table, the name of the table, or the name of the database used as the source of the values in a ComboBox or ListBox control. |
9 | Pop-up. Included for backward compatibility. |
For more information about using each of the RowSourceType settings, see "Using List Boxes and Drop-Down List Boxes" in Chapter 10, Using Controls, in the Programmer's Guide.