public var usersXML:XML= A B ; public function togglePretty():void{ XML.prettyPrinting = !XML.prettyPrinting; myTextArea.text = usersXML.toString(); }