Re: [Flashcoders] CS3: unexpected type

2007-08-23 Thread Geografiek
Thanks a lot Hans, Way over my head just now, but I'll keep your class to see if I can understand it in a later stage. About mixing the languages. Thanks for this tip also. I use Dutch for comments, variable names and class names to be able to distinguish my content from the programmers lingo

Re: [Flashcoders] CS3: unexpected type

2007-08-23 Thread Cedric Muller
I've got a different help :-) which promises that typeof returns: Array object Boolean boolean Functionfunction int number Number number Object object String string uintnumber XML xml XMLList xml oops, you're right, my mistake. checked the

Re: [Flashcoders] CS3: unexpected type

2007-08-23 Thread Geografiek
Hi Cedric, Thanks. var xmlData:XML = new XML(); did the trick. About typeof doesn't and will never return XML as a result. Look up the table in the help panel for 'typeof': I've got a different help :-) which promises that typeof returns: Array object Boolean boolean Function

Re: [Flashcoders] CS3: unexpected type

2007-08-23 Thread Hans Wichman
Hi, the differences in type checking between "i am a string" and new String ("i am a string") and xml and other objects is fairly annoying. ie: trace (typeof("string")); //traces string trace (typeof(new String("string"))); //traces object Same goes for other objects such as xml etc its all fairl

Re: [Flashcoders] CS3: unexpected type

2007-08-23 Thread Cedric Muller
look, maybe, here ... // just declaring the dataType won't be enough var xmlData:XML; trace(xmlData instanceof XML); // <- outputs: false // declaring the dataType and assigning an instance of XML var xmlData:XML = new XML(); trace(xmlData instanceof XML); // <- outputs: tr

Re: [Flashcoders] CS3: unexpected type

2007-08-23 Thread Geografiek
Sorry, typo The fla says 'var xmlData:XML'. Any other suggestions? Thanks, Willem Op 23-aug-2007, om 10:16 heeft Cedric Muller het volgende geschreven: and if you do: var xmlData:XML; ?? Cedric var xmlData:xml; =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+= Geografiek is a Dutch, Utrecht-based map

Re: [Flashcoders] CS3: unexpected type

2007-08-23 Thread Cedric Muller
and if you do: var xmlData:XML; ?? Cedric var xmlData:xml; ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Softwa

[Flashcoders] CS3: unexpected type

2007-08-23 Thread Geografiek
Hi list, The following puzzles me: //code in frame 1 1 var xmlData:xml; 2 trace(typeof(xmlData)); //'object' not xml?? //mijnXml.getHetXmlObject() is a method of a custom class that is supposed to return an xml-object //code that loads the xml is ommitte