In the Lynda.com title "ActionScript 3.0 in Flash CS3 Professional - Beyond the Basics" Todd Perkins shows how one way of typecasting
var xml: XML;
xml = event.target.data as XML
doesn't work, while
var xml: XML;
xml = XML(event.target.data)
does. Shouldn't both forms act the same way? How are they different?
TIA
Steven
edit
declarations added to the code