array info request (was: Re: Rant Re Rev Documentation)
keith
keith at vortex.co.uk
Mon Jul 25 15:35:08 EDT 2005
Sometime around 25/7/05 (at 13:40 -0400) Lynch, Jonathan said:
>Custom properties and custom property sets should have 1-word names.
>
>Somewhere in the docs it says otherwise, but having a space in the name
>of a custom property caused me trouble at one point, which was fixed
>when I made sure it just had a single-word name.
That's no problem, I name properties in that way out of habit, and I
have one eye on using MySQL at some point in the future. Sticking to
single-word names is one of the basics for working with MySQL. (So
basic that even *I* know about it! ;-)
>The internal order in which keys are stored in a custom prop is not
>sorted alphabetically
Oh boy...
>so, if you need to search in order, you might be
>better off doing something like this:
>
>Set the custompropertyset of me to "scheduledItems"
>Put the customkeys of me into tKeys
>Sort tKeys
>Repeat for each line L in tKeys
> If the scheduleditems[L] of me contains "my search string" then
> Do whatever it needs to do
> End if
>End repeat
I'll experiment. Thanks very much for this heads-up, it could well
have prevented me from nose-diving into the weeds! Any other comments
will be extremely welcome if anyone has the time and energy to add
'em.
k
More information about the use-livecode
mailing list