Purpose
Creates a workspace file representing the current MapInfo Pro session. You can issue this statement from the MapBasic window in MapInfo Pro.
Syntax
Save Workspace As filespec [ Mode ( Default | Current ) ] [ CharSet char_set ]
filespec is a string representing the name of the workspace file to create.
char_set a string constant, such as "WindowsLatin1".
Description
The Save Workspace statement creates a workspace file that represents the current MapInfo Pro session. The effect is comparable to the user choosing Save Workspace on the HOME tab, except that the Save Workspace statement does not display a dialog box.
When the Mode clause is set to Default, it saves the workspace without updating the current workspace title in MapInfo Pro application title bar. When set to Current, it saves the workspace and updates the current workspace title in MapInfo Pro application title bar.
The CharSet clause specifies a character set. The char_set parameter should be a string constant, such as "WindowsLatin1". If no CharSet clause is specified, MapBasic uses the system character set that is in use at runtime. See CharSet clause for more information. Using "UTF-8" as the workspace character set allows characters from any language to be represented.
To load an existing workspace file, use the Run Application statement.