Page 1 of 1
Save as defaulting to Legacy Livecode Stack (7_0)
Posted: Sun Jan 09, 2022 3:30 pm
by M-A Kuttner
Hi all. I've been writing a stack for a number of months now. I started in LC Community 9_6_2 and I'm now using LC 9_6_5 . Every time I Save As, the "Save as Type:" pulldown defaults to "Legacy Livecode Stack (7_0)", even though the version I'm working from was saved as "Livecode Stack" (and was started using Vers 9 in the first place). This happened in the previous version of LC I was using as well as the current one. Any pointers on what's going on here? Is it even saving as a current version stack? If it isn't, I'm a bit concerned that it may be contributing to some other flakiness.
Thanks in advance!
PS - dots are replaced with underscores in the versions above because the forum software thinks I'm trying to post a URL.

Re: Save as defaulting to Legacy Livecode Stack (7_0)
Posted: Sun Jan 09, 2022 3:42 pm
by Klaus
Hi M-A Kuttner,
PS - dots are replaced with underscores in the versions above because the forum software thinks I'm trying to post a URL.
due to lots of spamming here in the forum, you need to have a least seven postings before you can post e.g. active links.
And obviously something like 9.5.5 is considered as link by the forum software.
Best
Klaus
Re: Save as defaulting to Legacy Livecode Stack (7_0)
Posted: Sun Jan 09, 2022 3:48 pm
by richmond62
Any pointers on what's going on here?
If you do a "straight"
Save LiveCode will save your stuck in the current format.
AND, it is true that is you do a "
Save As" for some odd reason
LiveCode offers the version 7 format
as default (and I don't know why), but this is easily circumvented:
-
Re: Save as defaulting to Legacy Livecode Stack (7_0)
Posted: Mon Jan 10, 2022 4:10 am
by M-A Kuttner
Thanks very much! I just wanted to make sure it wasn't just me.
Re: Save as defaulting to Legacy Livecode Stack (7_0)
Posted: Mon Jan 10, 2022 2:40 pm
by Klaus
Please check -> minStackFileVersion in the dictionary to see the technical reason behind this "feature".
Re: Save as defaulting to Legacy Livecode Stack (7_0)
Posted: Mon Jan 10, 2022 5:43 pm
by stam
I can't reproduce this issue. I'm not in the habit of 'saving as' as i read somewhere it's better to just duplicate the file itself.
I opened an older stack created in 9.x
The
minStackFileVersion of the stack is empty and cannot be set
Doing a 'save as' defaults to the standard format, with options to save as legacy formats:
Re: Save as defaulting to Legacy Livecode Stack (7_0)
Posted: Mon Jan 10, 2022 5:48 pm
by richmond62
That is very useful to know.
Re: Save as defaulting to Legacy Livecode Stack (7_0)
Posted: Mon Jan 10, 2022 7:08 pm
by LCMark
@M-A Kuttner : So the logic in the IDE (and engine) goes to great lengths to ensure two things:
1. that you don't accidentally lose data as a result of saving a stack in a format which doesn't support all controls and properties your stack contains
2. that you don't accidentally save a stack in a format which would prevent it being opened by an older version
If you don't specify an explicit version, or specify a version which is >= 7, it will save the stackfile in the earliest format (>=7) which it can without there being any data loss.
If you specify a version < 7, then it will save it in the specified version - but the IDE will warn you that data loss might occur.
Basically, the engine can tell exactly what stackfile format is needed for a stack in terms of version 7 formats and onwards, but cannot tell if a stack could be saved in a version earlier than that - so it doesn't try.
Re: Save as defaulting to Legacy Livecode Stack (7_0)
Posted: Tue Jan 11, 2022 6:04 am
by M-A Kuttner
Thanks! I just posted another question about a corrupted stack. Could this be because I've been trying to save in a version above 7_0? I haven't added any extensions to it, though I did recently add a menu.
Re: Save as defaulting to Legacy Livecode Stack (7_0)
Posted: Tue Jan 11, 2022 8:35 am
by richmond62
Could this be because I've been trying to save in a version above 7_0?
Assuming you are using a newer version than LC 7: because if you aren't LC 7 would not give you the
option to save in a newer version.
If, for the sake of argument, you are using 9.6.x the natural thing when you perform a
SAVE
(as opposed to a
SAVE AS) is for LC 9.6.x to save your stack in the version 9 format which
should cause
NO problems whatsoever.
To be honest, I think that the reason for your stack becoming corrupted lies elsewhere.
I just posted another question about a corrupted stack.
Where did you post that, because I cannot find it?
Can you repost that Q here?
Re: Save as defaulting to Legacy Livecode Stack (7_0)
Posted: Tue Jan 11, 2022 8:39 am
by richmond62
it's better to just duplicate the file itself
Possibly, but it is useful to append
a version number to the thing whichever way you do things, otherwise
you can end up in a terrible pother.
Re: Save as defaulting to Legacy Livecode Stack (7_0)
Posted: Tue Jan 11, 2022 2:39 pm
by M-A Kuttner
Thank you Richmond. I appreciate your taking the time to respond.
Where did you post that, because I cannot find it?
Can you repost that Q here?
It's posted at the top of the same forum as this question -
Getting Started with LiveCode - Complete Beginners
Should be one or two questions under this one. The name of my post is "Stack getting flaky".
Cheers
M-A