Deleting Custom Properties

Mark Smith lists at futilism.com
Thu Jun 25 16:23:43 EDT 2009


Klaus, a slightly simpler way is to use the fact the "the  
customproperties" of an object is an array, so:

put the customproperties of btn "xyz" into tArray
delete variable tArray["propname"]
set the customproperties of btn "xyz" to tArray

Randy, it's worth looking into customPropertySets - "the  
customproperties" of an object is just the "current" customPopertySet  
of that object.

Best,

Mark


On 25 Jun 2009, at 19:47, Klaus on-rev wrote:

> Hi Randy,
>
>> Hi All,
>>
>> I've been playing with custom properties over the past several  
>> weeks for pretty much the first time.
>> I've been able to create, fill, and empty them via script...  
>> however, I've not been to delete one via script. How is that  
>> accomplished?
>
> this is the most cumbersome thingie in the whole Rev universe :-D
>
> Fact is, you have to:
> ...
> put the customkeys of btn "xyz into cp_list
> put lineoffset("propname_to_delete",cp_list) into line_nr
> delete line line_nr of cp_list
> set the customkeys of btn "xyz" to cp_list
> ...
>
> BTW, has this ever bee bugzilla'd as an enhancement?
>
>> take care,
>> randy hengst
>
> Best
>
> Klaus
>
> --
> Klaus Major
> http://www.major-k.de
> klaus at major.on-rev.com
>
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your  
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-revolution




More information about the use-livecode mailing list