I figured out the issue... :-(
Hhhhhhhhhh... Stupid!!
for( var i:int =0; i<LengthOfDelete; i++) {
Delete_ArrayofStructs.addItem(dgBanner.selectedItems[i]);
ArrayofStructs.removeItemAt(dgBanner.selectedIndices[i]);
}
Essentially I was adding elements to my DELETE array and then deleting what I
had in memory at the same time... Thus producing an array with NULL entries
in it. So when it came time for CF to do it's job, it ran into NULL array
elements....
Sorry to bother everyone here.
________________________________
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of John Mason
Sent: Wednesday, July 25, 2007 2:48 PM
To: [email protected]
Subject: RE: [AFFUG Discuss] Flex and CF Arrays
What does a dump of the variable show you?
John
[EMAIL PROTECTED]
________________________________
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Robert Capilli
Sent: Wednesday, July 25, 2007 2:43 PM
To: [email protected]
Subject: [AFFUG Discuss] Flex and CF Arrays
I have an Array In flex that has 3 elements in it.
I am passing this array to ColdFusion.
When I ask for the array length in CF it tells me I have 3 elements in
it..... Great, that's correct.
When I loop through the array in CF I am receiving:
[RPC Fault faultString="You have attempted to dereference a scalar variable
of type class java.lang.String as a structure with members."
faultCode="Server.Processing" faultDetail=""]
--------------------------Code: --------------------------
<cffunction name="DeleteData" access="public" returntype="String">
<cfargument name="myGridArray" type="Array" required="Yes"
default="NoValueSent">
<cfset TO = #ArrayLen(myGridArray)#>
<cfloop index="i" from="1" to="#TO#">
HI
</cfloop>
It appears that there is nothing in the 3rd location within the array from my
Flex App.
I know flex looks at arrays like:
[0]
[1]
[2]
Whereas CF looks at arrays like:
[1]
[2]
[3]
So when I am looping through the array in CF there is nothing at location 3.
Hence the error... SO my question is
1) Am I thinking about this correctly here?
2) How do I make the CF delete everything in the Array? Cause I cannot
do a loop from 0 to 3. It tells me: The element at position 0 cannot be
found." faultCode="Server.Processing" faultDetail=""]
-------------------------------------------------------------
To unsubscribe from this list, simply email the list with unsubscribe in the
subject line
For more info, see http://www.affug.com
Archive @ http://www.mail-archive.com/discussion%40affug.com/
List hosted by FusionLink <http://www.fusionlink.com>
-------------------------------------------------------------
-------------------------------------------------------------
To unsubscribe from this list, simply email the list with unsubscribe in the
subject line
For more info, see http://www.affug.com
Archive @ http://www.mail-archive.com/discussion%40affug.com/
List hosted by FusionLink <http://www.fusionlink.com>
-------------------------------------------------------------
-------------------------------------------------------------
To unsubscribe from this list, simply email the list with unsubscribe in the
subject line
For more info, see http://www.affug.com
Archive @ http://www.mail-archive.com/discussion%40affug.com/
List hosted by http://www.fusionlink.com
-------------------------------------------------------------