LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
-
paulgabel
- Posts: 31
- Joined: Tue Jun 19, 2007 7:03 pm
-
Contact:
Post
by paulgabel » Wed Aug 29, 2007 9:38 pm
A script in a card in one stack (SuperExam) is supposed to take me to a particular card in another stack (Questions) and then move the stack (Questions) and another stack (Examinee Controls). What happens is that I get a white screen/blank card, then after a second or so, when the new card is drawn correctly, the two stacks show up already moved. (I want them to move afterward.) If I go to the same card as I was at last time, it works fine, but if I go to a different card I get the white screen. As you can see, there are no lock screen or lock messages involved. I've been trying for several days to work around this "white screen" problem, but I can't seem to solve it. Can anyone help me?
Code: Select all
-- GO TO APPROPRIATE CARD
-- nextGoBack has been defined as a card name
hide stack "Questions"
go invisible cd nextGoBack of stack "Questions"
show stack "Questions"
hide stack "SuperExam Intro"
hide stack "SuperExam"
move stack "Examinee Controls" from 1115,525 to 985,525 in 20 ticks
move stack "Questions" from 840,525 to 710,525 in 20 ticks
move stack "Examinee Controls" from 985,525 to 1212,525 in 20 ticks
Rev 2.8.1 build 242
iMac Intel
OS 10.4.10
Paul Gabel
-
Mark
- Livecode Opensource Backer

- Posts: 5150
- Joined: Thu Feb 23, 2006 9:24 pm
-
Contact:
Post
by Mark » Wed Aug 29, 2007 11:08 pm
Hi Paul,
Something similar to the following should solve the problem. I haven't tested this and you may need to experiment a little more.
Code: Select all
on foo1
-- GO TO APPROPRIATE CARD
-- nextGoBack has been defined as a card name
hide stack "Questions"
go invisible cd nextGoBack of stack "Questions"
send "foo2" to stack "Questions" in 0 millisecs
end foo1
on foo2
show me
hide stack "SuperExam Intro"
hide stack "SuperExam"
move stack "Examinee Controls" from 1115,525 to 985,525 in 20 ticks
move stack "Questions" from 840,525 to 710,525 in 20 ticks
move stack "Examinee Controls" from 985,525 to 1212,525 in 20 ticks
end foo2
Best,
Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
-
paulgabel
- Posts: 31
- Joined: Tue Jun 19, 2007 7:03 pm
-
Contact:
Post
by paulgabel » Wed Aug 29, 2007 11:57 pm
I really appreciate your effort to solve my problem, but when I implemented your suggestion I got the same behavior that I had before — white screen for about 1 second, then correct card of other stack shows after the two-stack movement has (presumably) occurred. I put the "foo2" handler in the Questions stack script, and it received the send message, but there is no improvement. I also tried the send message without the "in 0 millisecs," but to no avail. Do you have any further suggestions for tweaking this handler, or another idea altogether? Do you know why this is happening? Thank you.
Paul Gabel
-
paulgabel
- Posts: 31
- Joined: Tue Jun 19, 2007 7:03 pm
-
Contact:
Post
by paulgabel » Thu Aug 30, 2007 12:07 am
I'M VERY EXCITED. RIGHT AFTER THE LAST POST, I TRIED AGAIN, THIS TIME USING "5 MILLISECS" INSTEAD OF "0 MILLISECS." NOW IT WORKS BEAUTIFULLY. YOU WERE RIGHT WHEN YOU SAID "YOU MAY NEED TO EXPERMENT A LITTLE MORE." THANK YOU VERY MUCH.

Paul Gabel