Open substack on lauch

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
croivo
Posts: 111
Joined: Wed Feb 26, 2014 11:02 pm

Open substack on lauch

Post by croivo » Sat Oct 17, 2015 2:26 pm

Is there any way to first start substack on application launch? By default it opens mainstack...
I'm using Livecode on Windows.

Klaus
Posts: 14199
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: Open substack on lauch

Post by Klaus » Sat Oct 17, 2015 2:31 pm

Dobar dan croivo,

hm, not directly, but you can try:
1. hide mainstack on preopenstack
2. open substack
3. close mainstack
4. set visible of (closed) mainstack back to true

Not tested, but sounds doable :D


Best

Klaus

croivo
Posts: 111
Joined: Wed Feb 26, 2014 11:02 pm

Re: Open substack on lauch

Post by croivo » Sat Oct 17, 2015 2:49 pm

Guten Tag Klaus,
I already tried something like that... On preopenstack I added code to close mainstack and open substack... And substack has the button to open mainstack. But when I click on that button, it's not gonna open mainstack because of that code on preopenstack handler on mainstack.
So, to conclude...
I want to open that substack on app launch, than click on button that opens mainstack. Hope I'm clear...

Danke schön :D

Klaus
Posts: 14199
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: Open substack on lauch

Post by Klaus » Sat Oct 17, 2015 3:12 pm

I would set a "flag" (variable or custom property) on the first preopenstack
so next time the script will not execute! Know what I mean?

croivo
Posts: 111
Joined: Wed Feb 26, 2014 11:02 pm

Re: Open substack on lauch

Post by croivo » Sat Oct 17, 2015 8:20 pm

Yep... I tried that, but looks like something was interfering my old code in stack, so it didn't work.
Anyway, I copied the substack card in mainstack and mainstack card in substack. And now it's working...

Post Reply