Custom Properties
Devin Asay
devin_asay at byu.edu
Thu Apr 13 11:24:33 EDT 2006
On Apr 12, 2006, at 6:55 PM, Mark Wieder wrote:
> Devin-
>
> Wednesday, April 12, 2006, 2:26:13 PM, you wrote:
>
>> The way I use it is much more pedestrian than the Marks'. For me it's
>
> Not pedestrian at all. I just tried to post a simple example that
> would do something useful. I use your technique all the time by having
> an "Initialize" method in my objects, although I would have coded your
> example as:
>
> setProp editMode pMode
> set the enabled of button "Save" to pMode
> set the enabled button "TextColor" to pMode
> set the lockText of fld "myfld" to pMode
> set the traversalOn of fld "myFld" to pMode
> end editMode
Yes, of course this is much better if your property is boolean.
Thanks for pointing out an efficiency that should have been obvious. :-)
>
> ...you only need to pass editMode if you need to set the real custom
> property and want to query it later on.
By 'set the real custom property' do you mean actually changing the
custom prop's value? Wouldn't you want to go ahead and set it in most
cases, except when you are intercepting an illegal value, for instance?
Devin Asay
Humanities Technology and Research Support Center
Brigham Young University
More information about the use-livecode
mailing list