I am parsing xml and I am trying to set each xml tag with the same name to a
different variable. This is what I have.
COVYEAR = XmlSearch(myxmldoc, "//COVERED/YR_INFO/YEAR");
for (i = 1; i LTE ArrayLen(COVYEAR); i = i + 1)
vCOVYEAR = COVYEAR[i].XmlAttributes["VALUE"];
How do I add the "i" index to the variable vCOVYEAR so that each element in
the array would be set to vCOVYEAR1, vCOVYEAR2, vCOVYEAR3, etc. etc.
Thanks in advance.
insuractive - 14 Mar 2007 22:33 GMT
Love ColdFusion Scope Structures. They are your friend:
Variables["vCovYear#i#"] = "SomeValue";
Anthony Spears - 15 Mar 2007 15:35 GMT
Michael,
Thanks a lot. Works perfectly!!!
Anthony