Arrays and Custom Props

Gregory Lypny gregory.lypny at videotron.ca
Sun Feb 15 13:00:43 CST 2009


Good stuff, Jim.  Well thought out.  Thanks for sharing it.

	Gregory

On Sun, Feb 15, 2009, at 1:00 PM, use-revolution-request at lists.runrev.com 
  wrote:

> Message: 9
> Date: Sat, 14 Feb 2009 16:45:24 -0800
> From: Jim Ault <JimAultWins at yahoo.com>
> Subject: Re: Arrays and Custom Props --not trivial- agreed
> To: How to use Revolution <use-revolution at lists.runrev.com>
> Message-ID: <C5BCA5A4.5522C%JimAultWins at yahoo.com>
> Content-Type: text/plain;	charset="US-ASCII"
>
>> Jim Ault's good overview in response to this thread
>> shows that strategies for developing a working relationship with
>> custom props is not trivial.
> Agreed.  Just as building a good set of database linked tables  
> (schema)
> takes some planning, so do custom properties.
>
> Accessing database records is very fast, and so is accessing a custom
> property.  Storing very large amounts of data in fields is a much,  
> much
> slower method of (storage, updating and accessing).  Most of us  
> don't build
> projects of large enough scale to see the difference.
>
> One of the great things about Rev is that you have choices.
> One trick for easy visibility plus fast operation is:
> --store settings and preferences in a field,
> --  then on closefield, copy the text to a single custom property
> --  just as you do the single field
> --   thus you can have it both ways!
> Good for the IDE and better for the user
>
> on closefield
>   put the short date && the short time into line 1 of me  --time stamp
>   set the cpPrefsField of this stack to me -- eg. fld  
> "prefsAndSettings"
>   save this stack
>   get the cpPrefsField of this stack
>   put the lineoffset("backgroundColor", it) into pos
>   put line 1 of it & cr & line pos of it into msg
> end closefield
>
> Compiling the standalone will lock in both versions of the text, but  
> script
> access using the custom property will be much faster.  Remember, any  
> changes
> to a field in a standalone can not be saved in the standalone, the  
> same for
> any changes made by the user or a script.
>
> Jim Ault
> Las Vegas




More information about the use-livecode mailing list