Deleting an object with a "bank shot'

T. R. Ponn alptex2 at orwell.net
Thu Aug 7 15:34:00 EDT 2003


Ken...THANK YOU!

...and now...I'm going off to fire me.  I've even suggested a "target" 
technique at the card level to somebody here a few weeks back. 
 Sometimes, I just seem to be able to snatch defeat from the jaws of 
victory with such ease...   ;-)

Best Regards,

Tim Ponn


Ken Ray wrote:

>Tim,
>
>How about simplifying it to:
>
>(script of card):
>
>on wackIt
>  delete the target
>end wackIt
>
>(script of the btn you want to delete):
>
>on mouseUp
>  send "wackit" to me in 10 milliseconds
>end mouseUp
>
>This way, it will get a chance to complete its script and then be
>deleted when the 'wackit' message passes through the button to the card
>script.
>
>Ken Ray
>Sons of Thunder Software
>Email: kray at sonsothunder.com
>Web Site: http://www.sonsothunder.com/ 
>
>  
>
>>-----Original Message-----
>>From: use-revolution-admin at lists.runrev.com 
>>[mailto:use-revolution-admin at lists.runrev.com] On Behalf Of T. R. Ponn
>>Sent: Thursday, August 07, 2003 10:06 AM
>>To: use-revolution at lists.runrev.com
>>Subject: Deleting an object with a "bank shot'
>>
>>
>>Hello all!
>>
>>I'm attempting to delete an object when I click on it.  Of 
>>course...no 
>>can do a frontal lobotomy on yourself...so, I'm trying to use 
>>the send 
>>"in time" structure to send a message to the card that the 
>>object is on. 
>> These are the handlers:
>>
>>in the card:
>>
>>on wackIt thisOne
>>     delete thisOne
>>end wackIt
>>
>>in the btn I want to delete:
>>
>>on mouseUp
>>     do "send wackIt ("&quote&"btn id"&&the id of me&quote&") to 
>>card"&&quote&"PGM Builder"&quote&&"in 1 tick"
>>end mouseUp
>>
>>
>>I've checked the mouseUp handler by substituting "put" for "do", and 
>>what I get in the msg box looks ok:
>>
>>send wackIt ("btn id 1297") to card "PGM Builder" in 1 tick
>>
>>But I get an error when attempting to execute the above from 
>>the msg box.
>>
>>
>>I know the "wackIt" handler is ok, because I've executed this 
>>from the 
>>msg box successfully:
>>
>>wackIt ("btn id 1297")
>>
>>
>>It seems to me that the send "in time" doesn't have the 
>>ability to pass 
>>the parameter.  Is this the problem?  Should I be using a "function" 
>>structure instead of the "on" structure?  I know I could 
>>accomplish this 
>>by using a global var, but this just seems more straight forward.
>>
>>Thanks in advance for any assistance!
>>
>>Best Regards,
>>
>>Tim Ponn
>>
>>_______________________________________________
>>use-revolution mailing list
>>use-revolution at lists.runrev.com 
>>http://lists.runrev.com/mailman/listinfo/use-> revolution
>>
>>    
>>
>
>
>_______________________________________________
>use-revolution mailing list
>use-revolution at lists.runrev.com
>http://lists.runrev.com/mailman/listinfo/use-revolution
>
>
>  
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.runrev.com/pipermail/use-livecode/attachments/20030807/6b583820/attachment.html>


More information about the use-livecode mailing list