You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/dictionary/command/save.lcdoc
+21-7Lines changed: 21 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -2,42 +2,56 @@ Name: save
2
2
3
3
Type: command
4
4
5
-
Syntax: save <stack> [as <filePath>]
5
+
Syntax: save <stack> [as <filePath>] [with format <stackFormat> | with newest format]
6
6
7
7
Summary: Saves a <stack file> on the user's system.
8
8
9
9
Introduced: 1.0
10
10
11
-
OS: mac,windows,linux,ios,android
11
+
OS: mac,windows,linux,ios,android,html5
12
12
13
13
Platforms: desktop,web,mobile
14
14
15
15
Security: disk
16
16
17
17
Example:
18
-
save stack "project1"
18
+
save stack "project1" with newest format
19
19
20
20
Example:
21
21
save this stack as "Backup"
22
22
23
23
Example:
24
24
save stack "project1" as "/Disk/Folder/File"
25
25
26
+
Example:
27
+
save stack "MyOldApp" with format 7.0
28
+
26
29
Parameters:
27
30
stack: Any open stack.
28
-
filePath: The filePath specifies the name and location of the file you want to save to. If you specify a name but not a location, LiveCode assumes the file is in the defaultFolder. If the file does not exist, LiveCode creates it.
29
31
30
-
The result: If the stack cannot be saved (for example, if you try to save it to a nonexistent drive or to a CD-ROM), the result <function> is set to "Can't open stack file".
32
+
filePath: The <filePath> specifies the name and location of the file you want to save to. If you specify a name but not a location, LiveCode assumes the file is in the <defaultFolder>. If the file does not exist, LiveCode creates it.
33
+
34
+
stackFormat: The <stack version|stack file format version> to use when saving.
35
+
36
+
The result: If the stack cannot be saved (for example, if you try to save it to a nonexistent drive or to a CD-ROM), the <result> will contain an error message. Otherwise, the <result> will be empty.
31
37
32
38
Description:
33
39
Use the <save> <command> to save changes to a <stack> or to save a copy of a <stack> into another <file>.
34
40
35
41
The <save> <command> saves all <stacks> stored in the same <file> as the specified <stack>. That is, if you save a <main stack>, all <substacks> of that stack are also saved in the same <file>, and if you save a <substack>, its <main stack> and any other <substacks> are also saved.
36
42
37
-
If the stack has not yet been saved and doesn't have a filename, you must use theform.
43
+
If the stack has not yet been saved and doesn't have a filename, you must use the `as` form.
38
44
39
45
You cannot save to a standalone application's file; <standalone application|standalones> are read-only.
The <save> command can save the <stack> in several different versions of the LiveCode stack file format.
48
+
49
+
* If you use the `with newest format` form of the <save> command, the <stack> is saved using the newest <stack version>
50
+
* If you use the `with format` form of the <save> command, the <stackFormat> should be the particular <stack version> you want the stack to be saved as.
51
+
* If you do not specify a format to use, the current value of the <stackFileFormat> property is used.
52
+
53
+
**Warning:** If you save in an older <stack version> that doesn't support all of the features used in the stack, then some of contents of the stack may be lost. In general, you are recommended to use the `with newest format` form of the <save> command.
54
+
55
+
References: substacks (property), stack (object), as (keyword), file (keyword), substack (glossary), stack file (glossary), command (glossary), standalone application (glossary), main stack (glossary), stacks (function), create stack (command), function (control_st), stack version (glossary), defaultFolder (property), stackFileFormat (property)
Copy file name to clipboardExpand all lines: docs/dictionary/function/systemVersion.lcdoc
+13-20Lines changed: 13 additions & 20 deletions
Original file line number
Diff line number
Diff line change
@@ -10,15 +10,15 @@ Summary: <return|Returns> the version number of the operating system.
10
10
11
11
Introduced: 1.0
12
12
13
-
OS: mac,windows,linux,ios,android
13
+
OS: mac,windows,linux,ios,android,html5
14
14
15
15
Platforms: desktop,server,web,mobile
16
16
17
17
Example:
18
18
the systemVersion
19
19
20
20
Example:
21
-
if the systemVersion is "8.6.0" then set the OSVersion to "8.6"
21
+
if the systemVersion begins with "10.11." then set the OSVersion to "10.11"
22
22
23
23
Returns: The <systemVersion> <function> <return|returns> a <string>.
24
24
@@ -27,29 +27,22 @@ Use the <systemVersion> <function> to determine whether the current version of t
27
27
28
28
The exact format of the <systemVersion> varies, depending on the operating system.
29
29
30
-
On Mac OS and OS X systems, the <systemVersion> returns three integers separated by decimal points. For example, on Mac OS 8.6, the <systemVersion> <return|returns> "8.6.0".
30
+
On Mac OS X systems, the <systemVersion> returns three integers separated by decimal points. For example, on Mac OS X "El Capitan", the <systemVersion> <return|returns> "10.11.0".
31
31
32
32
On Windows systems, the <systemVersion> returns the internal Windows version designation. The internal designations for several Windows versions are as follows:
33
33
34
-
* Windows 95 - Windows 4.0
35
-
* Windows 98 - Windows 4.10 (may return other numbers)
36
-
* Windows Me - Windows 4.90 (may return other numbers)
37
-
* Windows NT 4 - NT 4.0
38
-
* Windows 2000 - NT 5.0
39
-
* Windows XP - NT 5.1
40
-
* Windows Vista - NT 6.0
41
-
* Windows 7 - NT 6.1
34
+
* Windows XP: "NT 5.1"
35
+
* Windows Vista: "NT 6.0"
36
+
* Windows 7: "NT 6.1"
37
+
* Windows 8: "NT 6.2"
38
+
* Windows 8.1: "NT 6.3"
39
+
* Windows 10: "NT 10.0"
42
40
43
-
Because certain sub-versions of Windows 98 and Windows Me return slightly different values for the <systemVersion>, you can check for these versions by testing whether the number is in a range, as in the following example:
41
+
On iOS the <systemVersion> will return the iOS version number. For example, if the device has iOS 4.3 installed, this property returns "4.3"; if the device has iOS 3.1.3 installed, this property will return "3.1.3".
44
42
45
-
get word 2 of the systemVersion
46
-
if it >= 4.1 and it < 4.9 then answer "Windows 98!"
43
+
On Android the <systemVersion> will return the Android OS version number. For example, if the device has Android 2.2 installed, this property returns "2.2"; if the device has
44
+
Android 2.3.1 installed, this property will return "2.3.1".
47
45
48
-
On iOS the <systemVersion> will return the iOS version number. For example, if the device has iOS 4.3 installed, this property returns 4.3; if the device has iOS 3.1.3 installed, this property will return 3.1.3.
49
-
50
-
On Android the <systemVersion> will return the Android OS version number. For example, if the device has Android 2.2 installed, this property returns 2.2; if the device has
51
-
Android 2.3.1 installed, this property will return 2.3.1.
52
-
53
-
>*Note:* When running a Mac OS application in the Classic box on an OS X system, the <systemVersion> function returns the version number of the Classic system folder.
0 commit comments