In my application, I'm using HTTPservice to get data from a webservice. I receive the data in 'object' format which I'm directly binding to my controls.
The XML nodes are not expected to have any attributes, so all the leaves of the XML are assumed to be strings. For example: <Items> <Item> <id>2</id> <color>Red</color> <weight>2</weight> </Item> </Items> dataItem = event.result.Items.Item; <mx:TextInput text="{dataItem.color}"/> The problem I'm facing is that when there are whitespaces in database, the webservice (VB.NET) adds an attribute xml:space="preserve". This makes dataItem.color an object with an attribute xml:space instead of a simple string. Hope I explained the problem clearly enough. Is there any simple solution to this problem? Should I be getting the data in XML format instead and do the conversion to object tree myself? If yes, is there an easy way to do it while ignoring the xml:space attributes?