Re: [Flashcoders] XML Question

2010-11-04 Thread Taka Kojima
You would do xml..product.(@prodCode == id); Yep, that simple. Taka On Thu, Nov 4, 2010 at 11:17 AM, Matt S. mattsp...@gmail.com wrote: I know this is easy, but I'm having trouble finding the answer: if I'm iterating through XML like so: return xml.category.(@name ==

Re: [Flashcoders] XML Question

2010-11-04 Thread Matt S.
Yep, I knew it was gonna be something dead-simple ;) . Thanks Taka! .m On Thu, Nov 4, 2010 at 2:27 PM, Taka Kojima t...@gigafied.com wrote: You would do xml..product.(@prodCode == id); Yep, that simple. Taka On Thu, Nov 4, 2010 at 11:17 AM, Matt S. mattsp...@gmail.com wrote: I know this

Re: [Flashcoders] XML Question

2010-05-07 Thread John Singleton
- Original Message From: Merrill, Jason jason.merr...@bankofamerica.com To: Flash Coders List flashcoders@chattyfig.figleaf.com Sent: Thu, May 6, 2010 11:08:04 AM Subject: RE: [Flashcoders] XML Question Jason Merrill says he sent an earlier reply concerning my question about

Re: [Flashcoders] XML Question

2010-05-06 Thread allandt bik-elliott (thefieldcomic.com)
wrote: - Original Message From: kennethkawam...@gmail.com kennethkawam...@gmail.com To: Flash Coders List flashcoders@chattyfig.figleaf.com Sent: Wed, May 5, 2010 12:48:28 PM Subject: Re: [Flashcoders] XML Question Say for example you are in the home section and obtaining the data

Re: [Flashcoders] XML Question

2010-05-06 Thread John Singleton
Jason Merrill says he sent an earlier reply concerning my question about how to write my switch statement. No, I don't recall seeing it. I just resurrected it with Google, and thank you! This works: pageDetails = xmlData.PAGE.(@pg_name == contact).DETAILS.text(); Meanwhile,

Re: [Flashcoders] XML Question

2010-05-06 Thread John Singleton
Whoops. Now I have this in my XML: DETAILSh3Senior Citizen Discount/h3 bDelta Electric and Construction Co., Inc./b finds its pricing to be fair and reasonable. Their prices are competitive and based on the local market rates. Delta Electric offers a 10% discount to Senior Citizens living

Re: [Flashcoders] XML Question

2010-05-06 Thread tom rhodes
http://www.w3schools.com/xml/xml_cdata.asp On 6 May 2010 14:56, John Singleton johnsingleton...@yahoo.com wrote: Whoops. Now I have this in my XML: DETAILSh3Senior Citizen Discount/h3 bDelta Electric and Construction Co., Inc./b finds its pricing to be fair and reasonable. Their prices

Re: [Flashcoders] XML Question

2010-05-06 Thread kennethkawam...@gmail.com
Wrap your text with XML character data, i.e. DETAILS![CDATA[h3Senior Citizen Discount/h3... ]]/DETAILS -- Kenneth Kawamoto http://www.materiaprima.co.uk/ On 6 May 2010 13:56, John Singleton johnsingleton...@yahoo.com wrote: Whoops. Now I have this in my XML:    DETAILSh3Senior Citizen

Re: [Flashcoders] XML Question

2010-05-06 Thread John Singleton
- Original Message From: kennethkawam...@gmail.com kennethkawam...@gmail.com To: Flash Coders List flashcoders@chattyfig.figleaf.com Sent: Thu, May 6, 2010 9:08:22 AM Subject: Re: [Flashcoders] XML Question Wrap your text with XML character data, i.e. DETAILS![CDATA[h3Senior

RE: [Flashcoders] XML Question

2010-05-06 Thread Merrill, Jason
Jason Merrill says he sent an earlier reply concerning my question about how to write my switch statement. No, I don't recall seeing it. I just resurrected it with Google, and thank you! This works: Well, THAT's annoying (not your fault though)- do you see this reply? I hope I'm not being

Re: [Flashcoders] XML Question

2010-05-05 Thread Glen Pike
Hi, Your switch uses page_name, but your XML says pg_name. Not sure about the other question at the moment, but it looks like you are repeating your self in the switch statement - if all your pages have DETAILS, do you need to switch? I am guessing you may have pages that differ? HTH a

Re: [Flashcoders] XML Question

2010-05-05 Thread Paul Andrews
On 05/05/2010 13:49, John Singleton wrote: Hi; I have this in an external xml file: PAGE pg_name='index' DETAILSThis is some more of the home page./DETAILS /PAGE My objective is to use a switch statement like this: switch (xmlda...@page_name.tostring()) {

Re: [Flashcoders] XML Question

2010-05-05 Thread allandt bik-elliott (thefieldcomic.com)
i'd also recommend having a root node and an xml type declaration at the start a On 5 May 2010 14:05, Paul Andrews p...@ipauland.com wrote: On 05/05/2010 13:49, John Singleton wrote: Hi; I have this in an external xml file: PAGE pg_name='index' DETAILSThis is some more of the home

Re: [Flashcoders] XML Question

2010-05-05 Thread John Singleton
- Original Message From: allandt bik-elliott (thefieldcomic.com) alla...@gmail.com i'd also recommend having a root node and an xml type declaration at the start Right. Ok, here's my revised code: ?xml version=1.0? SITE PAGE pg_name='index' DETAILSThis is some more of the

Re: [Flashcoders] XML Question

2010-05-05 Thread jonathan howe
You forgot your break; statements, sir. On Wed, May 5, 2010 at 11:12 AM, John Singleton johnsingleton...@yahoo.comwrote: - Original Message From: allandt bik-elliott (thefieldcomic.com) alla...@gmail.com i'd also recommend having a root node and an xml type declaration at the

RE: [Flashcoders] XML Question

2010-05-05 Thread Merrill, Jason
Your switch statement doesn't work because it should look like this instead: PAGE pg_name='index' DETAILSThis is some more of the home page./DETAILS /PAGE switch (xmldata.pa...@pg_name) { case index: pageDetails =

Re: [Flashcoders] XML Question

2010-05-05 Thread kennethkawam...@gmail.com
It's not just about missing break, your switch statement fundamentally does not make sense (sorry ;) switch (xmldata.pa...@pg_name.tostring()) ... this evaluates to indexcontact as your trace shows, therefore none of your cases will pass the test. In order to make this work you have to iterate

Re: [Flashcoders] XML Question

2010-05-05 Thread John Singleton
- Original Message From: jonathan howe jonathangh...@gmail.com To: Flash Coders List flashcoders@chattyfig.figleaf.com Sent: Wed, May 5, 2010 11:23:25 AM Subject: Re: [Flashcoders] XML Question You forgot your break; statements, sir. You're right, however it makes no difference

Re: [Flashcoders] XML Question

2010-05-05 Thread John Singleton
- Original Message From: kennethkawam...@gmail.com kennethkawam...@gmail.com To: Flash Coders List flashcoders@chattyfig.figleaf.com Sent: Wed, May 5, 2010 11:53:53 AM Subject: Re: [Flashcoders] XML Question It's not just about missing break, your switch statement fundamentally

Re: [Flashcoders] XML Question

2010-05-05 Thread kennethkawam...@gmail.com
...@yahoo.com wrote: - Original Message From: kennethkawam...@gmail.com kennethkawam...@gmail.com To: Flash Coders List flashcoders@chattyfig.figleaf.com Sent: Wed, May 5, 2010 11:53:53 AM Subject: Re: [Flashcoders] XML Question It's not just about missing break, your switch statement

RE: [Flashcoders] XML Question

2010-05-05 Thread Mattheis, Erik (MIN - WSW)
- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of John Singleton Sent: Wednesday, May 05, 2010 11:03 AM To: Flash Coders List Subject: Re: [Flashcoders] XML Question - Original Message From: jonathan howe jonathangh

Re: [Flashcoders] XML Question

2010-05-05 Thread kennethkawam...@gmail.com
-Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of John Singleton Sent: Wednesday, May 05, 2010 11:03 AM To: Flash Coders List Subject: Re: [Flashcoders] XML Question - Original Message From: jonathan howe

Re: [Flashcoders] XML Question

2010-05-05 Thread John Singleton
- Original Message From: kennethkawam...@gmail.com kennethkawam...@gmail.com To: Flash Coders List flashcoders@chattyfig.figleaf.com Sent: Wed, May 5, 2010 12:48:28 PM Subject: Re: [Flashcoders] XML Question Say for example you are in the home section and obtaining the data

RE: [Flashcoders] XML Question

2010-05-05 Thread Merrill, Jason
: [Flashcoders] XML Question - Original Message From: kennethkawam...@gmail.com kennethkawam...@gmail.com To: Flash Coders List flashcoders@chattyfig.figleaf.com Sent: Wed, May 5, 2010 12:48:28 PM Subject: Re: [Flashcoders] XML Question Say for example you are in the home section

Re: [Flashcoders] XML Question

2010-05-05 Thread Kenneth Kawamoto
...@gmail.com To: Flash Coders List flashcoders@chattyfig.figleaf.com Sent: Wed, May 5, 2010 12:48:28 PM Subject: Re: [Flashcoders] XML Question Say for example you are in the home section and obtaining the data for it, you'd do: var pageData:XML = xmlData.PAGE.(@pg_name == index)[0]; Then build

Re: [Flashcoders] XML question with a test case

2010-02-06 Thread Alexander Farber
Thank you - I'll do, but On Sat, Feb 6, 2010 at 7:01 PM, Juan Pablo Califano califa010.flashcod...@gmail.com wrote: Because your second query returns an empty list instead of null. So, instead of checking for null, just check the length of the result. trace(describeType(xml1.lobby));

Re: [Flashcoders] XML question with a test case

2010-02-06 Thread Juan Pablo Califano
I don't think so. I think that's precisely the reason why it returns an empty list instead of null. So you can safely chain toghether diferent node names in your query. Cheers Juan Pablo Califano 2010/2/6 Alexander Farber alexander.far...@gmail.com Thank you - I'll do, but On Sat, Feb 6,

Re: [Flashcoders] XML question with a test case

2010-02-06 Thread Alexander Farber
Thank you ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Re: [Flashcoders] XML question

2006-08-24 Thread Scott Hyndman
Is your XML object set to ignoreWhite? http://livedocs.macromedia.com/flash/mx2004/main_7_2/wwhelp/wwhimpl/common/html/wwhelp.htm?context=Flash_MX_2004file=1896.html Scott On 24/08/06, Wouter [EMAIL PROTECTED] wrote: Hi list, I got an MS Acces database with data, which I converted to

RE: [Flashcoders] XML question

2006-08-24 Thread Wouter
Thanx! But ignoreWhite = true So that`s not it...any other ideas? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Scott Hyndman Sent: Thursday, August 24, 2006 4:14 PM To: Flashcoders mailing list Subject: Re: [Flashcoders] XML question Is your

Re: [Flashcoders] XML question

2006-08-24 Thread Scott Hyndman
Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Scott Hyndman Sent: Thursday, August 24, 2006 4:14 PM To: Flashcoders mailing list Subject: Re: [Flashcoders] XML question Is your XML object set to ignoreWhite? http://livedocs.macromedia.com/flash/mx2004/main_7_2/wwhelp

RE: [Flashcoders] XML question

2006-08-24 Thread Wouter
? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Scott Hyndman Sent: Thursday, August 24, 2006 4:14 PM To: Flashcoders mailing list Subject: Re: [Flashcoders] XML question Is your XML object set to ignoreWhite? http://livedocs.macromedia.com/flash

RE: [Flashcoders] XML question

2006-08-24 Thread Ryan Potter
To: 'Flashcoders mailing list' Subject: RE: [Flashcoders] XML question Thanx! But ignoreWhite = true So that`s not it...any other ideas? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Scott Hyndman Sent: Thursday, August 24, 2006 4:14 PM To: Flashcoders

RE: [Flashcoders] XML question

2006-08-24 Thread Wouter
5:51 PM To: Flashcoders mailing list Subject: RE: [Flashcoders] XML question Did you try condenseWhite on your textfield? http://livedocs.macromedia.com/flash/8/main/wwhelp/wwhimpl/common/html/w whelp.htm?context=LiveDocs_Partsfile=2740.html From the help files: var my_str:String = Hello

RE: [Flashcoders] XML question

2006-08-24 Thread Steven Sacks | BLITZ
Here's one way: myString.split(\r).join(); myString.split(\n).join(); And if you use my XString class (search the archives): myString.squeeze( ); might do the trick, too. ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or

Re: [Flashcoders] XML question

2006-08-24 Thread ryanm
But I found out I can do a find and replace on the empty lines in Dreamwever so I`m gonna play with that! If you have access to any decent text editor you should be able to get rid of them. I use UltraEdit for this, because it supports RegExp in the replace dialog. Basically, you just want

Re: [Flashcoders] XML question

2006-08-24 Thread ryanm
Here's one way: myString.split(\r).join(); myString.split(\n).join(); It sounds to me like he's trying to take a database and turn it into something that can be loaded directly by Flash, maybe for a distributed standalone app (CD, web download, etc). Depending on the size of the data, it

RE: [Flashcoders] XML question

2006-08-24 Thread Wouter
Yes, He is trying to do that exactly :) I got a db and have to use the data in Flash on a CD. :) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of ryanm Sent: Thursday, August 24, 2006 7:53 PM To: Flashcoders mailing list Subject: Re: [Flashcoders] XML

RE: [Flashcoders] XML question

2006-08-24 Thread Wouter
, 2006 7:48 PM To: Flashcoders mailing list Subject: Re: [Flashcoders] XML question But I found out I can do a find and replace on the empty lines in Dreamwever so I`m gonna play with that! If you have access to any decent text editor you should be able to get rid of them. I use UltraEdit

Re: [Flashcoders] xml question

2006-06-19 Thread Flash guru
thanks On 6/17/06, Paul Evans [EMAIL PROTECTED] wrote: On 16 Jun 2006, at 22:28, Flash guru wrote: I'm restricted to asp, but I'm a php native that is blind to the ways of asp I'm trying to leave the way of ASP behind - the following notes might be useful to you... A good quick ASP

RE: [Flashcoders] xml question

2006-06-16 Thread Merrill, Jason
If you can't use PHP, can you use anything else like ASP or Coldfusion? You'll need something like that to produce them. The Flash player, for security reasons, can't create XML files by itself on the server. You have to use something else along with Flash. This is also true of HTML - same

Re: [Flashcoders] xml question

2006-06-16 Thread Flash guru
I'm restricted to asp, but I'm a php native that is blind to the ways of asp On 6/16/06, Merrill, Jason [EMAIL PROTECTED] wrote: If you can't use PHP, can you use anything else like ASP or Coldfusion? You'll need something like that to produce them. The Flash player, for security reasons,

RE: [Flashcoders] xml question

2006-06-16 Thread Merrill, Jason
-Original Message- From: [EMAIL PROTECTED] [mailto:flashcoders- [EMAIL PROTECTED] On Behalf Of Flash guru Sent: Friday, June 16, 2006 5:28 PM To: Flashcoders mailing list Subject: Re: [Flashcoders] xml question I'm restricted to asp, but I'm a php native that is blind

Re: [Flashcoders] XML question

2005-12-07 Thread Ramon Tayag
use Delegate - import mx.utils.Delegate; var a:Array = new Array(); .. .. main.onLoad = Delegate.create(this, populateXML); function populateXML():Void { trace(a); } Goodluck, On 12/7/05, Flash guru [EMAIL PROTECTED] wrote: Hey all, here's the code i'm working

RE: [Flashcoders] XML question

2005-12-07 Thread Glenn J. Miller
Variable scope... Try declaring them *outside* the onLoad() function, because those variables conveniently drift out of scope (release themselves) as the code exits that function... Hope this helps... -- Dok Skyymap Inc. 770.321.3967 Office 770.321.3454 Fax -Original Message- From: