SET CONSOLE Command

See Also

Enables or disables output to the main Visual FoxPro window or to the active user-defined window from within programs.

Syntax

SET CONSOLE ON | OFF

Arguments

ON

(Default) Sends all output to the main Visual FoxPro window or to the active user-defined window.

OFF

Suppresses output to the main Visual FoxPro window or to the active user-defined window.

Remarks

SET CONSOLE is set to ON when you are using Visual FoxPro interactively, and it cannot be changed to OFF from the Command window. You can change the setting to OFF only from within a program.

SET CONSOLE affects some interactive Visual FoxPro dialog boxes. For example, if SET CONSOLE is set to OFF and you issue BROWSE when no table is open, Visual FoxPro displays an error message. If SET CONSOLE is set to ON in the same circumstances, Visual FoxPro displays the Open dialog box.

SET CONSOLE doesn't affect output from @ ... SAY. Output from @ ... SAY is controlled by the SET DEVICE setting.

Important   An error always sets SET CONSOLE to ON. Use SYS(100) to check the SET CONSOLE setting before the error occurred. For more information, see SYS(100) – Console Setting.