On Tuesday, Oct 12 1999, Richard MacLemale wrote: > OK, here's what I want to do... > > I have a stack named "Quizmaker." It has a button named "Create Quiz". > When the button is clicked, I want the script to: > > 1. Clone the stack (Quizmaker). > 2. Ask the user to supply a name using "ask file" > (1 and 2 could be in the reverse order...) > 3. Save the cloned stack as whatever they named it. > 4. Send a message to the newly named clone stack. > > I can do 1 - 3, but when I try to script 4, I can't seem to get it right. > The newly named cloned stack is not a main stack, there's no main stack > assigned, and so it refuses to accept any messages. How do I make the newly > named cloned stack a mainstack (of itself) via scripting? PLEASE help me if > you can!!!!!! Thanks in advance. You need to set the mainStack of the stack to itself, then save it as fileName. Of the top of my head (not tested): ask file "Save new stack as:" if it is empty then exit mouseUp put it into tFilePath set the itemDel to "/" put last item of tFilePath into tShortName clone this stack set the name of stack it to tShortName set the fileName of stack tShortName to tFilePath set the mainStack of stack tShortName to tShortName save stack tShortName send "whatever" to cd 1 of stack tShortName Regards, Kevin > Richard MacLemale > www.coolclassroom.com > [EMAIL PROTECTED] Kevin Miller <[EMAIL PROTECTED]> <http://www.xworlds.com/> Cross Worlds Computing, MetaCard Distributors, Custom Development. Tel: +44 (0)131 672 2909. Fax: +44 (0)1639 830 707.
