Then what you need is:
private var ns:Namespace = new Namespace(http://...;);
default xml namespace ns;
use namespace applies to AS3's namespace, has nothing to do with XML.
see: http://livedocs.adobe.com/flex/201/langref/statements.html for a clear
description
of: namespace, use namespace
OK, I tried the following code and it's not working:
var xml:XML = new XML(inputXML.text);
var ns:Namespace = xml.namespace();
var filterdXML:XMLList = new XMLList(xml..ns::folder.(id == 13));
outputXML.text = filterdXML.toXMLString();
But, if I add a prefix to the namespace declared in the XML,
Is Namespace only in Flex 3 SDK? (I'm using 2.01).
--- In flexcoders@yahoogroups.com, fourctv [EMAIL PROTECTED] wrote:
try this:
var xml:XML = new XML(inputXML.text); // get the xml
var ns:Namespace = xml.namespace(); // extract
the default namespace
Hello,
I got it to work. I had to change the e4x expression a little to get
it to work. I needed to qualify the ID with the namespace. So this
code works:
var xml:XML = new XML(inputXML.text);
var ns:Namespace = xml.namespace();
trace(xml.namespace());
var filterdXML:XMLList = new
The e4XParser I speak of is at:
http://www.adobe.com/devnet/flex/articles/e4x_04.html
--- In flexcoders@yahoogroups.com, Jim Hayes [EMAIL PROTECTED] wrote:
I've already included some
dynamic e4x expression parsers that I found on the web
Tod,
do you have the urls for those to hand?
OOops, nevermind about the Namespace in Flex 2.0. Memory lapse.
--- In flexcoders@yahoogroups.com, Todd [EMAIL PROTECTED] wrote:
Is Namespace only in Flex 3 SDK? (I'm using 2.01).
--- In flexcoders@yahoogroups.com, fourctv fourctv@ wrote:
try this:
var xml:XML = new
Also, I've discovered something interesting. In the XML Document, if
I provide a namespace prefix, i.e., xmlns:com=http://...; then it all
works as expected. So then my question becomes more about how to get
the default namespace, not prefixed with an alias, to become visible
to e4x.
Thanks,
@yahoogroups.com
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: E4X Namespace Issues...
Date: Thu, 17 Jan 2008 16:02:49 -
Hello,
I got it to work. I had to change the e4x expression a little to get
it to work. I needed to qualify the ID with the namespace. So this
code works
try this:
var xml:XML = new XML(inputXML.text); // get the xml
var ns:Namespace = xml.namespace(); // extract the default
namespace
trace('folder13:',xml..ns::folder.(id ==13)); // use it in the
E4X expression
hth
julio
9 matches
Mail list logo