When the program is driven from an automation script, an options string can be specified in the script that acts as the import options dialogs do in the program. The string consists of comma-separated parameters, which specify the behavior of the various import options.
Parameter |
Type |
Description |
Filter |
string |
MDB |
SQLSTR |
string |
SQL string indicating selection |
Table |
integer |
Numeric value of the table to import |
Example
This example shows how to import an Access MDB file with the various options.
CommandApi.Construct("Import")
CommandApi.Option("GuiEnabled", "False")
CommandApi.Option("AutoConnect", "True")
CommandApi.Option("ClearOptions", "False")
CommandApi.Option("Filter", "mdb")
CommandApi.Option("Options", "SQLSTR=; Table=2")
CommandApi.Option("Path", "C:/Path/To/Import/file.mdb")
CommandApi.Option("PersistOptions", "True")
CommandApi.Do()
Used by: Import
See Also