[flexcoders] XMLList, tree, and textinput

2010-04-04 Thread cholid cholid
Hi all, i've new problem
i have textInput to show some string object 


that the object i put from

txtName.text = ~address~

 then i want to use tree to show the txtName and make XMLList to make the tree







how to order the txtName in tree?
Thanks


  

Re: [SPAM] [flexcoders] XMLList question

2009-12-11 Thread invertedspear
I forgot I asked that question here too. I actually turned up a pretty simple 
function some dude developed to sort XML at 
http://freerpad.blogspot.com/2007/07/more-hierarchical-sorting-e4x-xml-for.html 
I then modified it a bit to do what I need and posted it here 
http://stackoverflow.com/questions/1869964/flex-newbie-xmllist-question. 

It's essentially the same thing as your suggesting but I couldn't use the set 
children easily since I had multiple note names and I only wanted to sort one. 

ex:

  
  
  
  

I only need to (and only can) sort  nodes but need to keep the 
 around.

Thanks for the help though, sorry I didn't post the answer I had found sooner.


--- In flexcoders@yahoogroups.com, "Tracy Spratt"  wrote:
>
> I don't believe you can sort an xmllist directly.  I use a function that
> takes the children of a node (XMLList), wraps it in an XMLListCollection,
> sorts it, then uses setChildren() to re-assign the sorted children to the
> parent.  I think I have posted that here actually.
> 
>  
> 
> Tracy Spratt,
> 
> Lariat Services, development services available



RE: [SPAM] [flexcoders] XMLList question

2009-12-11 Thread Russ Ferguson


Sent from my Windows Mobile® phone.

-Original Message-
From: Tracy Spratt 
Sent: Thursday, December 10, 2009 11:45 PM
To: flexcoders@yahoogroups.com 
Subject: RE: [SPAM] [flexcoders] XMLList question

I don't believe you can sort an xmllist directly.  I use a function that
takes the children of a node (XMLList), wraps it in an XMLListCollection,
sorts it, then uses setChildren() to re-assign the sorted children to the
parent.  I think I have posted that here actually.

 

Tracy Spratt,

Lariat Services, development services available

  _  

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
Behalf Of invertedspear
Sent: Tuesday, December 08, 2009 5:46 PM
To: flexcoders@yahoogroups.com
Subject: [SPAM] [flexcoders] XMLList question

 

  

Is it possible to sort an XMLList? All the examples I can find on it create
a new XMLListCollection like this:

MyXMLListCol = new XMLListCollection(MyXMLList);

I don't think the XMLListCollection in this case has any reference to the
XMLList so sorting it would leave my XMLList unsorted, is this correct?

How can I sort the XMLList directly?

Thanks ~Mike





RE: [SPAM] [flexcoders] XMLList question

2009-12-10 Thread Tracy Spratt
I don't believe you can sort an xmllist directly.  I use a function that
takes the children of a node (XMLList), wraps it in an XMLListCollection,
sorts it, then uses setChildren() to re-assign the sorted children to the
parent.  I think I have posted that here actually.

 

Tracy Spratt,

Lariat Services, development services available

  _  

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
Behalf Of invertedspear
Sent: Tuesday, December 08, 2009 5:46 PM
To: flexcoders@yahoogroups.com
Subject: [SPAM] [flexcoders] XMLList question

 

  

Is it possible to sort an XMLList? All the examples I can find on it create
a new XMLListCollection like this:

MyXMLListCol = new XMLListCollection(MyXMLList);

I don't think the XMLListCollection in this case has any reference to the
XMLList so sorting it would leave my XMLList unsorted, is this correct?

How can I sort the XMLList directly?

Thanks ~Mike





[flexcoders] XMLList question

2009-12-08 Thread invertedspear
Is it possible to sort an XMLList? All the examples I can find on it create a 
new XMLListCollection like this:

MyXMLListCol = new XMLListCollection(MyXMLList);

I don't think the XMLListCollection in this case has any reference to the 
XMLList so sorting it would leave my XMLList unsorted, is this correct?

How can I sort the XMLList directly?

Thanks ~Mike




[flexcoders] XMLList += operator

2009-12-02 Thread Breizo
Hi,
I am a bit puzzled by the XMLList operator +=.
I created the following small test code:
var xmll:XMLList = new XMLList();
xmll+=;
trace(xmll.toXMLString());
addX(xmll);
trace(xmll.toXMLString());
  
private function addX(x:XMLList):void{
  x+=;
  trace(x.toXMLString());
}
  
and I was expecting to see:





but instead I saw :




i.e., the += seems to create a new instance of the XMLList, it doesn't update 
the current one.
  
Can anyone confirm?
Thanks


RE: [SPAM] [flexcoders] XMLList refrence problem

2009-11-27 Thread Tracy Spratt
Why use an itemRenderer?  Looks like a labelFunction would do what you want.

 

Tracy Spratt,

Lariat Services, development services available

  _  

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
Behalf Of criptopus
Sent: Friday, November 27, 2009 10:33 AM
To: flexcoders@yahoogroups.com
Subject: [SPAM] [flexcoders] XMLList refrence problem

 

  

I have this...








With a datagrid with this in...







What do I put in the {} to get:

Non-Member to show up for data.usrstatus == 0
Member to show up for data.usrstatus == 1
etc.

Its been driving me crazy!

- Stephen





[flexcoders] XMLList refrence problem

2009-11-27 Thread criptopus
I have this...








With a datagrid with this in...







What do I put in the {} to get:

Non-Member to show up for data.usrstatus == 0
Member to show up for data.usrstatus == 1
etc.

Its been driving me crazy!

- Stephen




RE: [flexcoders] XMLLIst += operator problem

2009-09-27 Thread Breizo

Thanks Tracy,
But complex objects are passed by reference. Right after the assignment in
the function, the address of the variable is modified, i.e. += actually
creates a new variable...
- Breizo

Tracy Spratt-2 wrote:
> 
> Hmm, it is acting like the XMLList variable is being passed as a value and
> not a reference. 
> I can think of at least three other ways to do this. 
> Tracy Spratt,
> From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
> Behalf Of Breizo
> Sent: Friday, September 25, 2009 10:00 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] XMLLIst += operator problem
> Hi,
> Trying to do a simple element add to a XMLList but running into basic
> problems.
> Has anyone already fixed this?
> 
> When I run the example, I get:
> 
> 
> 
> 
> 
> when I would expect 
> 
> 
> 
> 
> 
> 
> Any idea?
> 
> Thanks
> 
> 
> http://www.adobe.
> <http://www.adobe.com/2006/mxml>
> com/2006/mxml" layout="absolute"
> applicationComplete="init();">
> 
> 
> -- 
> View this message in context: http://www.nabble.
> <http://www.nabble.com/XMLLIst-%2B%3D-operator-problem-tp25577790p25577790.h
> tml> com/XMLLIst-%2B%3D-operator-problem-tp25577790p25577790.html
> Sent from the FlexCoders mailing list archive at Nabble.com.
> 
> 
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/XMLLIst-%2B%3D-operator-problem-tp25577790p25629633.html
Sent from the FlexCoders mailing list archive at Nabble.com.



RE: [flexcoders] XMLLIst += operator problem

2009-09-26 Thread Tracy Spratt
Hmm, it is acting like the XMLList variable is being passed as a value and
not a reference. 

 

I can think of at least three other ways to do this. 

 

Tracy Spratt,

Lariat Services, development services available

  _  

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
Behalf Of Breizo
Sent: Friday, September 25, 2009 10:00 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] XMLLIst += operator problem

 

  


Hi,
Trying to do a simple element add to a XMLList but running into basic
problems.
Has anyone already fixed this?

When I run the example, I get:





when I would expect 






Any idea?

Thanks


http://www.adobe. <http://www.adobe.com/2006/mxml>
com/2006/mxml" layout="absolute"
applicationComplete="init();">


-- 
View this message in context: http://www.nabble.
<http://www.nabble.com/XMLLIst-%2B%3D-operator-problem-tp25577790p25577790.h
tml> com/XMLLIst-%2B%3D-operator-problem-tp25577790p25577790.html
Sent from the FlexCoders mailing list archive at Nabble.com.





[flexcoders] XMLLIst += operator problem

2009-09-25 Thread Breizo

Hi,
Trying to do a simple element add to a XMLList but running into basic
problems.
Has anyone already fixed this?

When I run the example, I get:





when I would expect 






Any idea?

Thanks



http://www.adobe.com/2006/mxml"; layout="absolute"
applicationComplete="init();">


-- 
View this message in context: 
http://www.nabble.com/XMLLIst-%2B%3D-operator-problem-tp25577790p25577790.html
Sent from the FlexCoders mailing list archive at Nabble.com.



[flexcoders] XMLList: get first n items

2009-01-03 Thread Hyder
How do I get the first n items in an XMLList?
I'm not very familiar with XML workarounds.

TIA,

Hyder



[flexcoders] XMLList to Number

2008-11-15 Thread Richard Rodseth
I'm decoding some XML and want to detect whether a particular element (whose
text should be a number) is present and use a default number if it isn't. It
seems that if

node.min

is not present the expression still returns an XMLList, so I'm doing
something like this:

private static function decodeNumber(value:XMLList):Number {
if (value.length() < 1) {
return NaN;
} else {
return new Number(value);
}

Are there some E4X tricks I'm missing?
More generally, any good XML decoders that work with a class map so I can
get typed AS objects?


[flexcoders] XMLList obtained after filtering to act as dataprovider to datagrid

2008-09-11 Thread samata
Hi,

I want the XMLList obtained after filtering to act as dataprovider 
to my datagrid...

Can some1 help me plz??

This is my code:


http://www.adobe.com/2006/mxml"; 
layout="absolute" creationComplete="init();">




  
  




 

 




Thanx,
sam



RE: [flexcoders] XMLList to ArrayCollection

2008-08-21 Thread Gordon Smith
Could you use an XMLListCollection instead of an ArrayCollection?

 

Gordon Smith

Adobe Flex SDK Team

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Tracy Spratt
Sent: Thursday, August 21, 2008 4:52 PM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] XMLList to ArrayCollection

 

Sure, but you have to do it manually.  Loop over the nodes, then use the
attributes() to loop over the attributes.  If I recall correctly,
attribute[n] will give you the attr value, and attribute[n].name() will
give you the attr name. XML.name() (or localName()) will give you the
name of the node.

 

Tracy

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of sdl1326
Sent: Thursday, August 21, 2008 5:56 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] XMLList to ArrayCollection

 

I am retrieving the following xml via httpsService with the result
format being 'e4x'. 


Q3
Q4
Q3
Q4
Q3
Q3
Q3
Q3


What's the best way to convert an XMLList to an ArrayCollection?  Is it
possible to do so without knowing the names of the attributes?

Thanks for the assistance.

 



RE: [flexcoders] XMLList to ArrayCollection

2008-08-21 Thread Tracy Spratt
Sure, but you have to do it manually.  Loop over the nodes, then use the
attributes() to loop over the attributes.  If I recall correctly,
attribute[n] will give you the attr value, and attribute[n].name() will
give you the attr name. XML.name() (or localName()) will give you the
name of the node.

 

Tracy

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of sdl1326
Sent: Thursday, August 21, 2008 5:56 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] XMLList to ArrayCollection

 

I am retrieving the following xml via httpsService with the result
format being 'e4x'. 


Q3
Q4
Q3
Q4
Q3
Q3
Q3
Q3


What's the best way to convert an XMLList to an ArrayCollection?  Is it
possible to do so without knowing the names of the attributes?

Thanks for the assistance.

 



[flexcoders] XMLList to ArrayCollection

2008-08-21 Thread sdl1326
I am retrieving the following xml via httpsService with the result
format being 'e4x'.

 Q3
 Q4
 Q3
 Q4
 Q3
 Q3
 Q3
 Q3

What's the best way to convert an XMLList to an ArrayCollection?  Is it
possible to do so without knowing the names of the attributes?

Thanks for the assistance.



RE: [flexcoders] XMLList -> XML Spontaneous Error

2008-06-27 Thread Tracy Spratt
Surprised this didn't error before.

 

All e4x expressions reuturn an XMLList, even if there is only one node.
So you have to do:

x = srv.lastResult.Term.Department.(@id==cDept).Course.(@num==cCrs)[0];
//to get the one and only XML node

Tracy



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of kenny14390
Sent: Friday, June 27, 2008 7:54 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] XMLList -> XML Spontaneous Error

 

Code that I haven't touched in months is now giving me errors at
runtime. It's compiling without even a warning, but when the
application is run, I get unexpected results. When I run the app in
debug mode, all breakpoints are ignored (news to me) so it's difficult
to find exactly what's wrong. I get the following error:

TypeError: Error #1034: Type Coercion failed: cannot convert
[EMAIL PROTECTED] to XML.
at Schedule/setWorkingCourse()[C:\Documents and Settings\Ricky\My
Documents\CS\Flex Projects\DDVSB2\src\Schedule.mxml:1286]...

So I went to that line and I found absolutely nothing wrong:

x = srv.lastResult.Term.Department.(@id==cDept).Course.(@num==cCrs);

x is defined a few lines up as x:XML. srv is the HTTPService that is
called upon creationComplete, and it is working just fine with the
rest of the application. cDept and cCrs are working fine as well.
Here's an example of the code that I'm trying to assign to x:



Discussion

1


That looks like valid XML to me! Apparently, it's an XMLList and that
is unable to be coerced to type XML. It's only been doing that for the
past few months with no problem. What could be the problem? Why is
Flex being so weird?

 



[flexcoders] XMLList -> XML Spontaneous Error

2008-06-27 Thread kenny14390
Code that I haven't touched in months is now giving me errors at
runtime. It's compiling without even a warning, but when the
application is run, I get unexpected results. When I run the app in
debug mode, all breakpoints are ignored (news to me) so it's difficult
to find exactly what's wrong. I get the following error:

TypeError: Error #1034: Type Coercion failed: cannot convert
[EMAIL PROTECTED] to XML.
at Schedule/setWorkingCourse()[C:\Documents and Settings\Ricky\My
Documents\CS\Flex Projects\DDVSB2\src\Schedule.mxml:1286]...

So I went to that line and I found absolutely nothing wrong:

x = srv.lastResult.Term.Department.(@id==cDept).Course.(@num==cCrs);

x is defined a few lines up as x:XML. srv is the HTTPService that is
called upon creationComplete, and it is working just fine with the
rest of the application. cDept and cCrs are working fine as well.
Here's an example of the code that I'm trying to assign to x:


  
Discussion
  
  1


That looks like valid XML to me! Apparently, it's an XMLList and that
is unable to be coerced to type XML. It's only been doing that for the
past few months with no problem. What could be the problem? Why is
Flex being so weird?



RE: [flexcoders] XMLList And ArrayCollection

2008-02-27 Thread Alex Harui
xml.gallery.photo.(@SubMenuID == "4")

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of NileAge, Mail
Sent: Wednesday, February 27, 2008 9:17 AM
To: [EMAIL PROTECTED]; 'Flex Components'; [EMAIL PROTECTED];
flexcoders@yahoogroups.com; [EMAIL PROTECTED]
Subject: [flexcoders] XMLList And ArrayCollection

 



  





















































  



 

Hello,

I'm have a above XML file. The question is how to get the items that
have SubMenuID="4"?

And I want to fill this xml file into ArrayCollection variable .

 



[flexcoders] XMLList And ArrayCollection

2008-02-27 Thread NileAge, Mail


  





















































  



 

Hello,

I'm have a above XML file. The question is how to get the items that have
SubMenuID="4"?

And I want to fill this xml file into ArrayCollection variable .



Re: [flexcoders] XMLList!!

2007-09-24 Thread Paul deCoursey
.item.child("koala").(text()=="Y")



figo2324 wrote:
>
> Hi people, i need your help, i have a xmllist object so i need to
> query this xmllist, im doing it in this way
>
> var jo:XMLList=myDataProvider.data.item.(koala=="Y");
>
> where myDataProvider.data =
> 
> 
> ccct
> X
> 
> 
> sambil
> Y
> 
> 
> then the structure of this xmllist can be changes it means that when
> i wanna to query it using this sentences var
> jo:XMLList=myDataProvider.data.item.(koala=="Y");
> The param koala have been changed, then i need that this param be a
> variable so i dont know how to do that...
>
> for example
>
> var variable:String="koala";//
> var jo:XMLList=myDataProvider.data.item.(variable=="Y");
> but it doesnt works, i dont know how to pass a variable in this
> sentence,
> i tried it
> var jo:XMLList=myDataProvider.data.item.([variable]=="Y");
> and
> var jo:XMLList=myDataProvider.data.item.({variable}=="Y");
> but it didnt work
> some suggestion please, im stuck in that
> Thanks coders...
>
>  



[flexcoders] XMLList!!

2007-09-24 Thread figo2324
 Hi people, i need your help, i have a xmllist object so i need to
 query this xmllist, im doing it in this way

 var jo:XMLList=myDataProvider.data.item.(koala=="Y");

 where myDataProvider.data =
 
 
 ccct
 X
 
 
 sambil
 Y
 
 
 then the structure of this xmllist can be changes it means that when
 i wanna to query it using this sentences var
 jo:XMLList=myDataProvider.data.item.(koala=="Y");
 The param koala have been changed, then i need that this param be a
 variable so i dont know how to do that...

 for example

 var variable:String="koala";//
 var jo:XMLList=myDataProvider.data.item.(variable=="Y"); 
 but it doesnt works, i dont know how to pass a variable in this
 sentence,
i tried it
var jo:XMLList=myDataProvider.data.item.([variable]=="Y");
and
var jo:XMLList=myDataProvider.data.item.({variable}=="Y");
but it didnt work
some suggestion please, im stuck in that
Thanks coders...



RE: [flexcoders] XMLList

2007-09-16 Thread Tracy Spratt
Yes, this has worked for me, though I always apply e4x expressions to an
XML node, never to an XMLList.  The XMLList is always what I get back.

Tracy

-Original Message-
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Ben Marchbanks
Sent: Sunday, September 16, 2007 7:57 AM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] XMLList

Interest to know if anyone has been able to make this work.

I struggled with trying to use variables in filtering XMLList without
success.

Alex Harui wrote:
> 
> 
> ([variable] == "Y")
> 
>  
> 
>

> 
> *From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]

> *On Behalf Of *figo2324
> *Sent:* Friday, September 14, 2007 2:46 PM
> *To:* flexcoders@yahoogroups.com
> *Subject:* [flexcoders] XMLList
> 
>  
> 
> Hi people, i need your help, i have a xmllist object so i need to
> query this xmllist, im doing it in this way
> 
> var jo:XMLList=myDataProvider.data.item.(koala=="Y");
> 
> where myDataProvider.data =
> 
> 
> ccct
> X
> 
> 
> sambil
> Y
> 
> 
> then the structure of this xmllist can be changes it means that when
> i wanna to query it using this sentences var
> jo:XMLList=myDataProvider.data.item.(koala=="Y");
> The param koala have been changed, then i need that this param be a
> variable so i dont know how to do that...
> 
> for example
> 
> var variable:String="koala";//
> var jo:XMLList=myDataProvider.data.item.(variable=="Y");
> but it doesnt works, i dont know how to pass a variable in this
> sentence, some suggestion please...
> 
> thanks so much coders
> 
> 

-- 
Ben Marchbanks

::: alQemy ::: transforming information into intelligence
http://www.alQemy.com

::: magazooms ::: digital magazines
http://www.magazooms.com

Greenville, SC
864.284.9918


--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links







Re: [flexcoders] XMLList

2007-09-16 Thread Ben Marchbanks
Interest to know if anyone has been able to make this work.

I struggled with trying to use variables in filtering XMLList without success.

Alex Harui wrote:
> 
> 
> ([variable] == “Y”)
> 
>  
> 
> 
> 
> *From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
> *On Behalf Of *figo2324
> *Sent:* Friday, September 14, 2007 2:46 PM
> *To:* flexcoders@yahoogroups.com
> *Subject:* [flexcoders] XMLList
> 
>  
> 
> Hi people, i need your help, i have a xmllist object so i need to
> query this xmllist, im doing it in this way
> 
> var jo:XMLList=myDataProvider.data.item.(koala=="Y");
> 
> where myDataProvider.data =
> 
> 
> ccct
> X
> 
> 
> sambil
> Y
> 
> 
> then the structure of this xmllist can be changes it means that when
> i wanna to query it using this sentences var
> jo:XMLList=myDataProvider.data.item.(koala=="Y");
> The param koala have been changed, then i need that this param be a
> variable so i dont know how to do that...
> 
> for example
> 
> var variable:String="koala";//
> var jo:XMLList=myDataProvider.data.item.(variable=="Y");
> but it doesnt works, i dont know how to pass a variable in this
> sentence, some suggestion please...
> 
> thanks so much coders
> 
> 

-- 
Ben Marchbanks

::: alQemy ::: transforming information into intelligence
http://www.alQemy.com

::: magazooms ::: digital magazines
http://www.magazooms.com

Greenville, SC
864.284.9918


--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

<*> Your email settings:
Individual Email | Traditional

<*> To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)

<*> To change settings via email:
mailto:[EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED]

<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
 


RE: [flexcoders] XMLList

2007-09-15 Thread Alex Harui
([variable] == "Y")

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of figo2324
Sent: Friday, September 14, 2007 2:46 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] XMLList

 

Hi people, i need your help, i have a xmllist object so i need to
query this xmllist, im doing it in this way

var jo:XMLList=myDataProvider.data.item.(koala=="Y");

where myDataProvider.data =


ccct
X


sambil
Y

 
then the structure of this xmllist can be changes it means that when
i wanna to query it using this sentences var
jo:XMLList=myDataProvider.data.item.(koala=="Y");
The param koala have been changed, then i need that this param be a
variable so i dont know how to do that...

for example

var variable:String="koala";//
var jo:XMLList=myDataProvider.data.item.(variable=="Y"); 
but it doesnt works, i dont know how to pass a variable in this
sentence, some suggestion please...

thanks so much coders 

 



[flexcoders] XMLList

2007-09-15 Thread figo2324
Hi people, i need your help, i have a xmllist object so i need to
query   this xmllist, im doing it in this way

var jo:XMLList=myDataProvider.data.item.(koala=="Y");

where myDataProvider.data =




ccct

X





sambil
Y

 

then the structure of this xmllist can be changes it means that when
i wanna to query it using this sentencesvar
jo:XMLList=myDataProvider.data.item.(koala=="Y");
The param koala have been changed, then i need that this param be a
variable so i dont know how to do that...

for example

var variable:String="koala";//
var jo:XMLList=myDataProvider.data.item.(variable=="Y");
but it doesnt works, i dont know how to pass a variable in this
sentence, some suggestion please...

thanks so much coders   



[flexcoders] XMLList and ToggleToolbar

2007-09-14 Thread Gates Matthew Stoner

I'm trying to take a XML structure that I'm returning via a remote
service and use it as a dataProvider for a Toogletoolbar. The XML is a
bit complex and has some nested nodes. Here is a small example of it


   
   Schnauzr
   


I want the toolbar to just be the topic labels (Dog, Cat). But I'm
getting an error about using a complex object. How do I just populate
the toolbar with the topic labels from my xml?

Matt



Re: [flexcoders] XMLList converted to XML

2007-04-11 Thread keith
Thanks !
-- Keith H --

Tracy Spratt wrote:
>
> One way”:
>
> var points:XMLList=obj.POINT;
>
> var obj:XML = ;
>
> obj.setChildren(points);
>
> Tracy
>
> 
>
> *From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
> *On Behalf Of [EMAIL PROTECTED]
> *Sent:* Tuesday, April 10, 2007 11:23 AM
> *To:* flexcoders@yahoogroups.com
> *Subject:* [flexcoders] XMLList converted to XML
>
>
> What is an efficient way to convert XMLList object into children of an
> XML object?
>
> I'm using the XMLList methods to rearrange my XML children to specified
> order, but I need to convert the reordered XMLList back into datatyped
> XML objects into the original XML object.
>
> var obj:XML=
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> ;
>
> var points:XMLList=obj.POINT;
>
> //How would convert "points" XMLList back into datatype XML children of
> the variable "obj"?
>
> --Keith H--
>
>
>  




--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

<*> Your email settings:
Individual Email | Traditional

<*> To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)

<*> To change settings via email:
mailto:[EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED]

<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
 


RE: [flexcoders] XMLList converted to XML

2007-04-10 Thread Tracy Spratt
One way":

var points:XMLList=obj.POINT;

var obj:XML = ;

obj.setChildren(points);

 

Tracy

 

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of [EMAIL PROTECTED]
Sent: Tuesday, April 10, 2007 11:23 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] XMLList converted to XML

 


What is an efficient way to convert XMLList object into children of an
XML object?

I'm using the XMLList methods to rearrange my XML children to specified
order, but I need to convert the reordered XMLList back into datatyped
XML objects into the original XML object.

var obj:XML=











;

var points:XMLList=obj.POINT;

//How would convert "points" XMLList back into datatype XML children of
the variable "obj"?

--Keith H--

 



[flexcoders] XMLList converted to XML

2007-04-10 Thread khair

What is an efficient way to convert XMLList object into children of an
XML object?

I'm using the XMLList methods to rearrange my XML children to specified
order, but I need to convert the reordered XMLList back into datatyped
XML objects into the original XML object.

var obj:XML=

  
   
   
   
  
  
   
   
   
  
;

var points:XMLList=obj.POINT;


//How would convert "points" XMLList back into datatype XML children of
the variable "obj"?

--Keith H--
begin:vcard
n:HAIR;KEITH
fn:KEITH HAIR
version:2.1
email;internet:[EMAIL PROTECTED]
end:vcard



RE: [flexcoders] xmlList vs. Array

2007-01-09 Thread Tracy Spratt
It ususlly depends on what format you get your data in.  I almost always
use xml between the server and Flex, so when I consume that data, I use
using e4x expressions, which return XML and  XMLList.

 

If I was using a back-end + RPC protocol that didn't steer so heavily
towards xml, and was receiving my data as objects or Arrays, I might not
be using  xml.

 

One note:  if you plan to update  the data on the client, use either
ArrayCollection, or XML, or XMLListCollection.  These APIs emit the
events necessary for Flex to know to update the visual controls.

 

Tracy

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of boy_trike
Sent: Tuesday, January 09, 2007 1:38 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] xmlList vs. Array

 

I am populating combo boxes and other lists with data that is either
hardwired into the 
application or retrieved from a database. An Array (or ArrayCollection)
seems to fit the bill in 
most cases and is very easy to access / update. What is the advantage of
using an XMLList 
assuming that my data is rectangular (no nested children). Is there any
performance or other 
advantages to XMLList? I notice that many of the flex examples seem to
use XML and I was 
wondering what I am missing?

Bruce

 



[flexcoders] xmlList vs. Array

2007-01-09 Thread boy_trike
I am populating combo boxes and other lists with data that is either hardwired 
into the 
application or retrieved from a database.  An Array (or ArrayCollection) seems 
to fit the bill in 
most cases and is very easy to access / update.  What is the advantage of using 
an XMLList 
assuming that my data is rectangular (no nested children).  Is there any 
performance or other 
advantages to XMLList?  I notice that many of the flex examples seem to use XML 
and I was 
wondering what I am missing?

Bruce



RE: [flexcoders] XMLList/XMLListCollection: sort on attributes

2006-12-04 Thread Deepa Subramaniam
Assuming the XMLListCollection created from the myData XML object looks
like this:

public var col:XMLListCollection = new
XMLListCollection(myData.children());

Then you would sort on the category name like so:

private function applyMySort():void
{
var s:Sort = new Sort();
s.fields = [new SortField("@name")];
col.sort = s;
col.refresh();
}

As for your second question, we don't support e4x expressions in the
sort field. To get that behavior you'll have to write your own
compareFunction that compares on the values you desire. You'll find that
the mx.utils.ObjectUtil class has all the comparators you'd need to do
this. 

Cheers,
deepa

-Original Message-
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Oliver Lietz
Sent: Monday, December 04, 2006 6:55 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] XMLList/XMLListCollection: sort on attributes

Hello List,

is there a way to sort a XMLList/XMLListCollection on their items
attributes?
What has to be done to sort the sample myData from "Using the 
XMLListCollection class" [1] on the category name?
Or is it possible to sort when making an E4X query?

tia,
O.

[1] 
http://livedocs.macromedia.com/flex/2/docs/wwhelp/wwhimpl/common/html/ww
help.htm?context=LiveDocs_Parts&file=0513.html#403970








--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links





[flexcoders] XMLList/XMLListCollection: sort on attributes

2006-12-04 Thread Oliver Lietz
Hello List,

is there a way to sort a XMLList/XMLListCollection on their items attributes?
What has to be done to sort the sample myData from "Using the 
XMLListCollection class" [1] on the category name?
Or is it possible to sort when making an E4X query?

tia,
O.

[1] 
http://livedocs.macromedia.com/flex/2/docs/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Parts&file=0513.html#403970








[flexcoders] XMLList with a single item as a dataprovder

2006-08-07 Thread Rick Root
Why can the XMLList object with a single node and no subitems be used as 
a dataprovider for a list driven item, such as a tree, but I can't dump 
it out using the inherited toString() method?

For an example, please take a look at the following simple flex app.  It 
contains two trees, each populated with data from an XMLList object. 
One of those has only a single node with no subitems, the other has a 
single node with one subitem.

https://www.it.dev.duke.edu/temp/flex/bin/Test.html
source: https://www.it.dev.duke.edu/temp/flex/Test.txt

As you can see, in both cases, the data shows up in the tree items 
exactly as you would expect.  But when I try to dump it to a textarea, 
the XMLList object with the single node and no subitems doesn't appear.

I have read the documentation on XML on livedocs and looked at the 
XMLList documentation as well.  Allegedly, the answer to my question is 
in there but I can't find it.

rick


--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
 





[flexcoders] XMLList as dataProvder for TileList

2006-03-08 Thread Jonathan Bezuidenhout



Hi,I create a XMLList result from a query by using the e4x method - and I would like to use this as the data provider for a TileList.In the TileList I create a custom component as a listItemRenderer, and in that component I use 
e.g. [EMAIL PROTECTED] to try and display the value of my attribute.The weird thing is that I get a TileList created with only one row in it (the XML has 5), and all the values for each field is concatenated.
So instead of seeing rows with values145I see one row with value 145.Hopefully this makes sense.  Is there any trick to make this work?ThanksJonathan






--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com








  
  
SPONSORED LINKS
  
  
  

Web site design development
  
  
Computer software development
  
  
Software design and development
  
  


Macromedia flex
  
  
Software development best practice
  

   
  







  
  
  YAHOO! GROUPS LINKS



   Visit your group "flexcoders" on the web. 
   To unsubscribe from this group, send an email to: [EMAIL PROTECTED] 
   Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.