Set focusable property via script? - Answer

Marian Petrides mpetrides at earthlink.net
Wed Jun 30 18:02:38 EDT 2004


After sending this query, I noticed that if I dwell for any length of 
time with my mouse over button that sets the desired property in the 
Object Inspector, a toolTip came up with the name of the property.  
Thus I found that traversalOn makes an object focusable if it is true 
and lockText makes an object's text locked if true.

So simply putting a temporary button on card 1 of the stack, containing 
the following script  allowed me to lock text in all fields and make 
the fields not focusable:


on mouseUp
   repeat with j = 1 to the number of cards
     go card j
     repeat with x = 1 to the number of fields
       set the traversalOn of field x to false
--make field not focusable
     end repeat
   end repeat
end mouseUp

repeat with j = 1 to the number of cards
     go card j
     repeat with x = 1 to the number of fields
       set the traversalOn of field x to false
     end repeat
end repeat

M





On Jun 30, 2004, at 5:24 PM, Marian Petrides wrote:

> I have a stack with a very large number of cards.  Now that I am done 
> entering text into the fields on these cards, I want to be sure that 
> each field is locked and that it is not focusable.
>
> Is there a way to set these properties from script?  I'd hate to have 
> to check each and every one manually.
>
> And, yes, I did look in the dox, even searched but I don't see a 
> property called focusable, nor one called locked.
>
> Thanks.
>
> M
>
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> http://lists.runrev.com/mailman/listinfo/use-revolution
>


More information about the use-livecode mailing list