> I am having problems with ArraySort() function. Has a
> 2 dimensional array with one column having text and
> the other having integers. Here is what I am doing:
>
> <cfscript>
> ArraySort(PartnerArray, "text");
> </cfscript>
>
> And it gives me this error:
>
> The expression has requested a variable or an
> intermediate expression result as a simple value,
> however, the result cannot be converted to a simple
> value. Simple values are strings, numbers, boolean
> values, and date/time values. Queries, arrays, and COM
> objects are examples of complex values.
>
> Any ideas? Not much documentation that I could find
> on ArraySort()
ArraySort, like all of the array functions, can only be used on
one-dimensional arrays. A two-dimensional array in CF is nothing more,
really, than a one-dimensional array in which each element is itself a
one-dimensional array. You're asking ArraySort to sort your outer array
(PartnerArray) by the elements within it, which are themselves arrays.
Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/
voice: (202) 797-5496
fax: (202) 797-5444
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists