Dave,

I had an interesting thing happen the other day. I was messing around
with something, trying to find a way around a particular problem, and
I used this code... fully expecting it to error out:

<cfset myTest = structNew()>

<cfloop from="1" to="5" index="i">
     <cfset myTest[i] = "some text, whatever was in the array I was
actually looping."
</cfloop>

Now, had I put myTest["#i#"], I would have expected it to work. What I
ended up with when I dumped it was a struct that looked very much like
an array.

This was on CFMX 6.1, just kinda struck me odd.

Laterz,
J


On Fri, 11 Feb 2005 14:21:48 -0500, Dave Watts <[EMAIL PROTECTED]> wrote:
> 
> "2" is not a valid variable name. If you use dot notation with structures
> and their members, you must use valid CF variable names for those members.
> If you want to use arbitrary strings for those members, you must use array
> notation:
> 
> lines["2"]
> 
> Dave Watts, CTO, Fig Leaf Software
> http://www.figleaf.com/
> 
> Fig Leaf Software provides the highest caliber vendor-authorized
> instruction at our training centers in Washington DC, Atlanta,
> Chicago, Baltimore, Northern Virginia, or on-site at your location.
> Visit http://training.figleaf.com/ for more information!
> 
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:194431
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to