Skip to content

SET_AUTOSAVE

SET_AUTOSAVE changes the autosave settings.

Syntax

leo-grammar
CC "Modeling" SET_AUTOSAVE	Enabling [ changes:intValue] .


Enabling :	on | off | enabled:boolValue .


# --> RESULT ecode:intValue .
CC "Modeling" SET_AUTOSAVE	Enabling [ changes:intValue] .


Enabling :	on | off | enabled:boolValue .


# --> RESULT ecode:intValue .

Parameters

  • <main-parameter> (enumValue) - one of: on | off (without quotation marks)
  • enabled (boolValue) -
  • changes (intValue, optional) -

Returns

  • ecode (intValue) - Contains the error code or is 0 in case of success.

Details

The user can change the autosave settings in the dialog "Auto save..." in the menu "Extra":

SET_AUTOSAVE

Autosave is turned on by passing the argument on or enabled:1. It can be turned off by passing off or enabled:0.
The argument changes specifies after how many model changes (e.g. create a new class, change an attribute, ...) the model should be automatically saved. The default value is 1 (i.e. autosave after each single change).

See Also

Examples

asc
CC "Modeling" GET_AUTOSAVE
CC "Modeling" SET_AUTOSAVE off
# ... (some actions)
CC "Modeling" SET_AUTOSAVE enabled:(enabled) changes:(changes)
CC "Modeling" GET_AUTOSAVE
CC "Modeling" SET_AUTOSAVE off
# ... (some actions)
CC "Modeling" SET_AUTOSAVE enabled:(enabled) changes:(changes)

The first CC saves the current autosave status. After that, autosaving is switched off.
The last CC restores the original autosave settings.

Versions and Changes

Available since ADOxx 1.3