'put URL' fails if previous 'put URL' call hasn't finished

Andre Garzia soapdog at mac.com
Mon Oct 11 16:31:44 EDT 2004


Trevor,

I did a silly as hell semaphore function called SafePut which is just a 
wrapper for put but it checks for a global prior to putting, if the 
global is set then it waits and loop, when the global is unset, it does 
the put url and sets the global. Don't know what happens if the put 
URLs are issued at the same time, I think one should implement a Queue 
data type and goes poping the puts when it's safe... or rev team could 
do that...

Cheers
andre


On Oct 11, 2004, at 6:00 PM, Trevor DeVore wrote:

> Hi,
>
> I have been doing some tests with web connected apps in Revolution and 
> came across an interesting behavior with the put URL command.
>
> It seems that if you call 'put URL' once and then issue another 'put 
> URL' command before  the first one finishes then the second one will 
> not complete but return empty immediately, allowing the second one to 
> finish.  I came across this in the following scenario:
>
> 1) Option menu calls handler which calls 'put URL'
> 2) Handler called from the option menu in turn calls another handler 
> that uses 'put URL' after a slight delay (using send command).
> 3) If the second handler hasn't finished downloading the requested 
> data and the user makes another selection from the option menu then 
> the 'put URL' handler called from the option menu will return empty 
> immediately.
>
> Is there any way around this (i.e. cancel previous put statement) or 
> do I just need to modify the interface so that this collision of put 
> statements never occurrs?
>
> Thanks,
>
> -- 
> Trevor DeVore
> Blue Mango Multimedia
> trevor at mangomultimedia.com
>
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> http://lists.runrev.com/mailman/listinfo/use-revolution
>
>
-- 
Andre Alves Garzia ð 2004 ð BRAZIL
http://studio.soapdog.org



More information about the use-livecode mailing list