Encryption problem?

Barry Levine themacguy at macosx.com
Mon Sep 1 01:11:01 EDT 2003


I have a stack with a handler in a field's script as follows:

on mouseDown
   put the clickChunk into whatWasClicked
   put the value of whatWasClicked into theWord
   if there is an image theWord then
     set the lockScreen to true
     put the loc of image theWord into myLoc
     -- for brevity later in this script
     copy image theWord to this stack
     put word 3 of it into myNewImageID
     -- that should be the ID# of the newly created image
     set the loc of image ID myNewImageID to myLoc
     show image ID myNewImageID
     set the lockScreen to false
     wait 1.25 seconds -- or do whatever
     delete image ID myNewImageID
     select empty
   end if
end mouseDown

It all works just fine until I encrypt it with a password at 
Distribution. I suspect that the name of the image is scrambled somehow 
as the image I'm copying never appears and the "wait 1.25 seconds" is 
not occurring. If I open that stack with the IDE, the problem persists. 
However, if I provide the password when I open a script in that stack, 
everything begins working until I close (& remove from memory) the 
stack. I do not have to change anything in the stack for it to begin 
working; just providing the password makes it work fine.

My images are named "mail" or "letter" or "post office", etc.. All 
paths to the jpegs are properly referenced (myresources/mail.jpeg). 
I've used this technique (referring to a referenced image by its object 
name) before and within encrypted stacks.

I don't understand what I may have changed to bring on this behavior. 
Any suggestions will be appreciated.

Thanks,
Barry




More information about the use-livecode mailing list