PeterH wrote:Marco wrote:
Let me know if you find this useful.
Sorry to say: I don't exactly understand it.
For me it seems: you load your default tabset, and restore it under the name of previous.
If you now load a tabset, your default is gone?
(PS, after having written the rest of this post:
Looking at it again I see I didn't notice that "Saveas" switches to the new (here: old

) name. That is: you assume that your "current" tabset is what I name "temp". Meaning: the tabset you start XY with is only temp...)
I'd had taken the other way round: after loading a tabset an immediate "Save as dummy" - now a "save" wouldn't destroy the original.
(But the current would always be named "dummy"
and the XY original tabset would always be in risk to being destroyed...)
So I'm convinced that changing the behavior of XY is the best.
After that I can load a tabset "pictures 1" anytime without without any risk, and everything is fine.
My whole setup has been this:
1. creating my "default" tabset and saving it;
2. then making an active copy through the command "saveas": this is the tabset where I work, mess around and what not.
When I execute the script I first get the name of the tabset where I work (the "messed" one), then simply reload the default one, delete the messed one so the last operation (saveas) can take place, since the new tabset has the same name of the first one. Yes, I'm basically bouncing between default and messed.
So eventually you understood correctly the functioning of my script. The default never risks anything, because is just loaded and then "duplicated" via "saveas".
admin wrote:Did you see the new "loadas" command: it loads a clone of a stored tabset under a new name. Isn't that what you want?
Yes it is, but consider this:
"saveas" operates on the current (active) tabset and requires a filename as input, which can be given via the script;
"loadas" may require a filename, but will also (in a second phase) popup a window asking for another filename (the name of the "cloned" tabset).
Since I want my script to be totally automatic I have to use saveas.