In this case you may use String as parameter for the constructor.

var xmlList:XMLList = new XMLList('<user pos="0" money="123"
changed="2" pool="10.20.30" whist1="10.20" whist2="100" /><user
pos="2" money="-123" changed="4" mount="1.2.3"whist1="10.20.100.300"
whist2="100" />');

You can also use Boolean and Number as parameter :)
-- 
Kenneth Kawamoto
http://www.materiaprima.co.uk/

On 10 February 2010 14:37, Alexander Farber <[email protected]> wrote:
> Sorry for one more probably basic XML question,
> but how do you create an XMLList object? I've tried:
>
> var list:XMLList =
> <user pos="0" money="123" changed="2" pool="10.20.30" whist1="10.20"
> whist2="100" />
> <user pos="2" money="-123" changed="4" mount="1.2.3"
> whist1="10.20.100.300" whist2="100" />
> ;
>
> var list:XMLList = XMLList(
> <user pos="0" money="123" changed="2" pool="10.20.30" whist1="10.20"
> whist2="100" />
> <user pos="2" money="-123" changed="4" mount="1.2.3"
> whist1="10.20.100.300" whist2="100" />
> );
>
> var list:XMLList = XMLList('
> <user pos="0" money="123" changed="2" pool="10.20.30" whist1="10.20"
> whist2="100" />
> <user pos="2" money="-123" changed="4" mount="1.2.3"
> whist1="10.20.100.300" whist2="100" />
> ');
>
> These all return errors, like for the 2nd one:
>
> 1084: Syntax error: expecting rightparen before pos.
>
> Regards
> Alex
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to