I have a cd “homepage” and a cd “editpage”. There’s a code in the card script on my cd “editpage” that states:
Code: Select all
On backkey
Go to cd “homepage”
End backkey
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Code: Select all
On backkey
Go to cd “homepage”
End backkey
Code: Select all
global gMyPrevCD
on mouseup
put the short name of this cd into gMyPrevCD
end mouseup
Code: Select all
global gMyPrevCD
on preopencard
if gMyPrevCD = “editdishes” then -- gMyPrevCD is the name of a global variable
else
-- do something
end if
put empty into gMyPrevCD -- don't forget to reset variable
end preopencard
Code: Select all
on preopencard
if the short name of recent cd = “editdishes” then
## Do this
else
## Do something else
end if
end preopencard