| **Navigation:**  [[database drivers.htm|Database Drivers]] >====== Driver Strings ====== | [[common database driver features.htm|{{btn_prev_n.gif|Previous page}}]][[database drivers.htm|{{btn_home_n.gif|Return to chapter overview}}]][[softvelocity common dialogs filedrivers selectfiledriverdialog.htm|{{btn_next_n.gif|Next page}}]] | | || There are switches or "driver strings" you can set to control the way your application creates, reads, and writes files with a specific driver. Driver strings are simply messages or parameters that are sent to the file driver at run-time to control its behavior. The various driver specific driver strings are described in the //Driver Strings //section for each driver. Driver strings are sent in three ways: with the OPEN or CREATE statement, with the SEND procedure, and with property syntax. **DRIVER('Driver', '/DriverString = value')** The OPEN(file) and CREATE(file) statements send any driver strings specified in the FILE's DRIVER attribute. OPEN sends the string immediately //before //the file is opened. You may specify these driver strings with a hand coded FILE declaration (see //[[driver specify data file type .htm|DRIVER]] //in the //Language Reference// for more information) or in the Data Dictionary (**Driver Options **field in the **File Properties**// //dialog--see //File Properties// ). In either case, you must prepend a forward slash (/) to the driver string. For example: **MyFile FILE,DRIVER('TopSpeed','/LOGFILE=MyFile.Log')** ** CODE** ** OPEN(MyFile)         !sends the LOGFILE driver string** **SEND(file, 'DriverString')** The SEND function sends a driver string to the file driver at any time, including before the file is opened. SEND functions take two forms--//with //an equal sign to change the value of the switch, and //without //an equal sign to return the value of the switch. With SEND, the ISAM drivers do not require the preceeding forward slash, but the SQL drivers do require it. For example: **SEND(MyFile,'LOGFILE='&MyLogFile)             !Set the logfile** **MyLogFile=SEND(MySQLFile,'/LOGFILE')          !Query the logfile** **OldLogFile=SEND(MyFile,'LOGFILE='&NewLogFile) !Set & Query the logfile** **file{PROP:DriverString}** Property syntax is an alternative to the SEND function. With property syntax you can send a driver string to the file driver any time //after //the file is opened. With property syntax, the driver string does not require the preceeding forward slash. For example: **MyLogFile = 'MyFile.Log'** **MyFile{PROP:Profile}=MyLogFile   !Set the logfile** **MyLogFile = MyFile{PROP:Profile} !Query the logfile** **See Also:** [[ascii driver strings.htm|ASCII Driver Strings]] [[basic driver strings.htm|Basic:Driver Strings]] [[btrieve driver strings.htm|Btrieve:Driver Strings]] [[clarion driver strings.htm|Clarion:Driver Strings]] [[clipper driver strings.htm|Clipper:Driver Strings]] [[dbaseiii driver strings.htm|dBaseIII:Driver Strings]] [[dbaseiv driver strings.htm|dBaseIV:Driver Strings]] [[dos driver strings.htm|DOS:Driver Strings]] [[foxpro driver strings.htm|FoxPro:Driver Strings]] [[topspeed driver strings.htm|TopSpeed: Driver Strings]] [[sql driver strings.htm|SQL Driver Strings]] [[mssql accelerator driver strings.htm|MSSQL Accelerator Driver Strings]] [[h532eu.htm|ODBC:Driver Strings]] [[oracle accelerator driver strings.htm|Oracle Accelerator Driver Strings]] [[sqlanywhere accelerator driver strings.htm|SQLAnywhere Accelerator Driver Strings]]