Messages in setprop...

David Bovill david at openpartnership.net
Tue Dec 6 05:56:52 EST 2005


So you want a recursive setProp handler :)

I have not tested this in a while (and there are a few little thins  
that don't work quite as expected with these - they do not return  
arrays for instance) - but I would try to avoid putting too much code  
in the setprop / getprop handlers and use them to call functions ( a  
recursive function in your case).


On 29 Nov 2005, at 14:34, Gilberto Cuba wrote:

> Example:
>
> setprop MyPropSet[propName] newValue
>
> switch propName
> case "Prop1"
>   -- (1)
>   set the MyPropSet["Prop3"] of me to value
>   break
> case "Prop2"
>   ...
>   -- do something...
>   ...
>   break
> case "Prop3"
>   ...
>   ...do something...  (2)
>   ...
>   break
> end switch
>
> end setprop
>
> When i set a value to a property "Prop1", it come in to (1), but  
> when the next line is executing, it dont pass for (2).
> I hope you might understand.




More information about the use-livecode mailing list