Merge stacks

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
Gurki
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 30
Joined: Wed Jul 10, 2013 6:34 pm

Merge stacks

Post by Gurki » Wed May 23, 2018 8:47 am

Hello,

Is there a way to merge stacks? - or to copy complete cards with included files, buttons, pictures and sounds?

The children created each an one-card stack about a month and I would like to put them together to have one stack with 12 cards.

G.

jmburnod
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2718
Joined: Sat Dec 22, 2007 5:35 pm
Location: Genève
Contact:

Re: Merge stacks

Post by jmburnod » Wed May 23, 2018 10:14 am

Hi,
Is there a way to merge stacks? - or to copy complete cards with included files,
buttons, pictures and sounds?
Files: Do you mean text in fields ?
Pictures are external files (referenced images) or paint images ?
Sounds are audioclips or external files ?
What about scripts ?

Of course ou may use copy and paste cd but its depends what is your final project.
In my practice with children, each user have his own folder with images and sound files.
Best regards
Jean-Marc
https://alternatic.ch

Gurki
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 30
Joined: Wed Jul 10, 2013 6:34 pm

Re: Merge stacks

Post by Gurki » Wed May 23, 2018 12:21 pm

Hi jmburnod

There are
- fields with text
- buttons
- pictures imported as File -> Import As Control -> Image File
- sound imported as File -> Import As Control -> Audio File

In this objects is some small code as on mouseUp, etc.

As all have the same background picture (a landscape) in a different month, the idea was to put it together to have one stack with the possibility to move from one card/month to the next and explore it (buttons/text fields explains plants and animals).

G.

MaxV
Posts: 1579
Joined: Tue May 28, 2013 2:20 pm
Location: Italy
Contact:

Re: Merge stacks

Post by MaxV » Wed May 23, 2018 1:11 pm

Use copy, example

Code: Select all

copy card 1 of stack "Childstack1" to stack "dad"
Livecode Wiki: http://livecode.wikia.com
My blog: https://livecode-blogger.blogspot.com
To post code use this: http://tinyurl.com/ogp6d5w

jmburnod
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2718
Joined: Sat Dec 22, 2007 5:35 pm
Location: Genève
Contact:

Re: Merge stacks

Post by jmburnod » Wed May 23, 2018 1:54 pm

Hi,
If you copy/paste a card, you copy all objects with script and script card but not
audioClip.
I never used audioclip, I use external files for all sounds
Not sure.there is a way to export audioclip to external file
http://forums.livecode.com/search.php?k ... +audioclip
Jean-Marc
https://alternatic.ch

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7228
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: Merge stacks

Post by jacque » Wed May 23, 2018 4:35 pm

One way to make sure all resources are included would be to make each stack a substack of a new mainstack. The new mainstack could have a list of each substack and clicking on a list line would open the correct substack.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”