actionscript 3 - AS3 Error: The public attribute can only be used inside a package -
I keep this error in AS3 and would like some help, basically this code is surrounded by package statement such as: Package {code ...}.
This gave me this error: "packages can not be nested", so when I take a package statement, "I use the public feature only a package" error, so I really do not know Running, here is the code .. Please help:
import flash.display.Loader; Import flash.display.Sprite; Import flash.events.Event; Import flash.net.URLLoader; Import flash.net.URLRequest; Public Class Main Sprite Extends {var _xml: XML; Public function chief () {super (); LoadXMLFile (); } Private function loadXMLFile (): zero {var loader = new URL loader (new URLRequest ("xml / tema1.xml")); Loader.addEventListener (event.complete, loadedCompleteHandler); } Private function loaded. FullHandler (E: Event): Zero {e.target.removeEventListener (Event.Complete, LoadedCampleHandler); _xml = e.target.data; Each (var cont: _xml.tema1 in XML) {statusField.text + = "imagen:" + tema1.contenido + "\ n"; Trace ("imagen:" + cont.image); }}}
Comments
Post a Comment