Partager via


Special Terms for Configuration Files

The following table lists special terms you can use in configuration files. You can also SET commands, system variables, and the _STARTUP setting in configuration files to customize the Visual FoxPro environment.

Remarks

Term and syntax

Description

ALLOWEXTERNAL ON | OFF

Specifies whether settings from an external configuration file as specified by the -C command-line switch (or located in path) are read in after those from an internal one. The ALLOWEXTERNAL term is ignored unless it is bound inside of an application.

Default: OFF

BITMAP ON | OFF

Specifies whether Visual FoxPro first writes screen or form updates to an off-screen bitmap, and then performs a bit block transfer (bitblt) to the screen. BITMAP = OFF can improve performance when application are accessed using Windows Terminal Server clients.

Default: ON

CODEPAGE = nValue | AUTO

Specifies a number that identifies the character set used for files. Setting CODEPAGE to AUTO selects the current operating system code page.

For the possible values you can use, see Code Pages Supported by Visual FoxPro.

COMMAND = cVisualFoxProCommand

Specifies a Visual FoxPro command to execute when Visual FoxPro is started. The cVisualFoxProCommand specifies the command to execute.

EDITWORK path

Specifies where the text editor should place its work files. Because work files can become large, specify a location with plenty of free space.

Default: Operating system dependent. For more information, see Optimizing the Operating Environment.

INDEX extension

Specifies the extension for Visual FoxPro index files.

Default: .idx

LABEL extension

Specifies the extension for Visual FoxPro label definition files.

Default: .lbx

_MENUDESIGNER = cProgramName

Specifies an external menu design application.

Default: The empty string "".

MVCOUNT

Sets the maximum number of variables that Visual FoxPro can maintain. This value can range from 128 to 65,000.

Default: 16,384

OUTSHOW = ON | OFF

Disables the ability to hide all windows in front of the current output by pressing SHIFT+CTRL+ALT.

Default: ON

PROGCACHE = nMemoryPages

Specifies the amount of memory (address space) in pages that Visual FoxPro allocates at startup or a Visual FoxPro MTDLL COM Server allocates per thread for the internal program cache (memory used to run programs). Each page of memory is equal to 64K so the default setting equates to an allocation a little over 9MB. As the cache is filled, Visual FoxPro will try to flush it to remove unused items. It is possible that Visual FoxPro cannot free enough memory in which case an Error 1202 is generated (Program is too large). Adjusting the PROGCACHE setting can prevent this error from occurring.

Note

While this setting can be used for the Visual FoxPro development product or normal runtime applications, it is primarily intended for MTDLL COM Servers where many threads are often created for a single server. In Visual FoxPro 9.0, the default value for MTDLL COM Servers is -2.

When the value of nMemoryPages is greater than 0, Visual FoxPro allocates a fixed program cache. You can specify between 1 and 65000.

If you specify 0 for nMemoryPages, no program cache is used. Instead, Visual FoxPro uses dynamic memory allocation based on determinations made by the operating system.

If you pass a value for nMemoryPages that is less than 0, Visual FoxPro uses dynamic memory allocation but is limited to the specified memory (nMemoryPages * 64K). When the limit is reach, Visual FoxPro will flush allocated programs to free memory.

You can call SYS(3065) to determine the current PROGCACHE setting. CLEAR PROGRAM will attempt to clear unreferenced code regardless of this setting.

Note

The Visual FoxPro OLE DB Provider ignores this setting since it uses dynamic memory allocation (PROGCACHE=0).

Default: 144 (-2 for MTDLL)

PROGWORK path

Specifies where Visual FoxPro stores the program cache file.

For faster performance, especially in a multiuser environment, specify a fast disk, such as a local disk or memory, if available. Provide at least 256K for the cache, though the file can grow larger.

Default: Operating system dependent. For more information, see Optimizing the Operating Environment.

REPORT extension

Specifies the extension for Visual FoxPro report definition files.

Default: .frx

RESOURCE path[\file] | OFF

Specifies the location of the FoxUser.dbf resource file or prevents Visual FoxPro from using a resource file. The file argument is optional. If file is omitted, Visual FoxPro searches for the FoxUser.dbf file. If the specified file does not exist, it is created.

Default: Startup directory as path and FoxUser.dbf as file.

SCREEN = ON | OFF

Specifies whether the main Visual FoxPro window appears when opening Visual FoxPro.

When an application consists of one or more top-level forms that are displayed in the Windows desktop, setting SCREEN to OFF can be useful, making the main Visual FoxPro window not required. For further information on top-level forms, see Controlling Form Behavior.

Default: ON

SORTWORK path

Specifies where commands such as SORT and INDEX should place work files.

Because work files can be up to twice as large as the tables being sorted, specify a location with plenty of free space. For faster performance, especially in a multiuser environment, specify a fast disk such as a local disk.

Default: Operating system dependent. For more information, see Optimizing the Operating Environment.

STACKSIZE = nValue

Specifies the number of nesting levels from 32 to 64,000 for operations such as the DO command.

Note

You can change the nesting level only during Visual FoxPro startup.

Default: 128

TEDIT [/N] editor

Specifies the name of the text editor used when you edit program files with MODIFY COMMAND or MODIFY FILE.

Include the optional clause /N with TEDIT to specify a Windows text editor.

Default: Visual FoxPro editor

TITLE title

Specifies the title that appears in the caption bar of the main Visual FoxPro window.

Default: "Microsoft Visual FoxPro"

TMPFILES path

Specifies where temporary work files specified by EDITWORK, SORTWORK, and PROGWORK configuration file settings are stored if they are not specified.

Because work files can become very large, specify a location with plenty of free space. For faster performance, especially in a multiuser environment, specify a fast disk such as a local disk.

Default: Operating system dependent. For more information, see Optimizing the Operating Environment.

See Also

Concepts

Setting Configuration Options at Startup

Reference

SET Command Overview

Other Resources

Optimizing Applications

Visual FoxPro Environment Settings