You can get the length via XMLList.length() so just substract 1 and
you'll have the last position.

________________________________

From: [email protected] [mailto:[EMAIL PROTECTED] On
Behalf Of mocalocamm
Sent: Monday, May 28, 2007 8:22 AM
To: [email protected]
Subject: [flexcoders] How to access last node atributes with e4x?



This is my xml:

<list>
<month month="3" year="2007">
<day date="01" impressions="407"/>
etc...
</month>
<month month="4" year="2007">
etc...
<day date="30" impressions="657"/>
</month>
</list>

More months will be added with time so I need to set a variable always
with the values of the lastest month:

endDate = new Date(2007,5,30)

Accessing the beginning of the month is easy enough:
startDate = new
Date([EMAIL PROTECTED],[EMAIL PROTECTED],[EMAIL PROTECTED]);

But how to get to the last node attributes if the last mode is
constantly changing?

Thanks for any help,
Moca



 

Reply via email to