Opening and closing projects

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
exheusden
Posts: 170
Joined: Fri Oct 09, 2009 5:03 pm
Location: Belgium
Contact:

Opening and closing projects

Post by exheusden » Wed Jan 27, 2010 10:14 pm

Whenever I start a Revolution by double-clicking on a .rev file, it starts up with the Revolution splash screen showing, then goes into what I call the "edit mode" of the project, with the toolbox displayed and the pointer tool selected.

And whenever I close a project (usually by clicking the close window button), Revolution asks me if I want to save changes to the stack, even if I am unaware of any changes having been made, other than moving from one card to another.

How can I change things to start a project without showing the splash screen and witht he pointer tool selected (and the toolbox not showing)?

How can I avoid the save warning when closing?

massung
Posts: 93
Joined: Thu Mar 19, 2009 5:34 pm

Re: Opening and closing projects

Post by massung » Thu Jan 28, 2010 5:16 pm

Sounds like you just want to run your stack as an application... why not just save it as a standalone? Even though this code is untested, something you can try as a work-around if you didn't want to use a standalone...

Code: Select all

## in the first card of the main stack's script...

on preOpenStack
   if the environment is "development" then
      choose the run tool
   end if
end preOpenStack

on closeStack
   if the environment is "development" then
      delete this stack
   end if
end closeStack
I have no idea if that will get rid of your save prompt, though... it's just a guess. Still, I think what you really want is to just save a standalone application and run it. ;)

HTH,
Jeff M.

exheusden
Posts: 170
Joined: Fri Oct 09, 2009 5:03 pm
Location: Belgium
Contact:

Re: Opening and closing projects

Post by exheusden » Thu Jan 28, 2010 6:40 pm

I take it, then, that it is normal behaviour for Revolution Media to start up in the edit mode, rather than in the mode in which the project was last closed.

I don't really want to save as standalone: I fear it will complicate matters, as I access other stacks and also I might well need to work on the stack later without disturbing its data. Would that be possible with a standalone? Can one revert to an editable version?

massung
Posts: 93
Joined: Thu Mar 19, 2009 5:34 pm

Re: Opening and closing projects

Post by massung » Thu Jan 28, 2010 8:00 pm

When you create a standalone (which, BTW, I don't believe you can do with RevMedia), it essentially makes a "copy" of your stack that is an EXE - or APP on Mac. Your .REV file remains untouched. You can keep editing it, update it, change it, save it as a standalone again and again.

Jeff M.

exheusden
Posts: 170
Joined: Fri Oct 09, 2009 5:03 pm
Location: Belgium
Contact:

Re: Opening and closing projects

Post by exheusden » Thu Jan 28, 2010 8:12 pm

The standalone option is not an option, then. The projects store data that regularly changes and I wouldn't want to change the data in both a standalone and in an editable rev project -- too much hassle and too great a danger of error. And if a standalone can't be made in Revolution Media, then it' certainly not an option, of course. (Indeed, in the UsersGuide.pdf, only revStudio and revEnterprise are mentioned.)

massung
Posts: 93
Joined: Thu Mar 19, 2009 5:34 pm

Re: Opening and closing projects

Post by massung » Thu Jan 28, 2010 8:41 pm

You may want to look at the save stack and load stack commands for use in a standalone. But, ya, that's probably moot anyway since you are using revMedia.

Jeff M.

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”