tag:robotlegs.tenderapp.com,2009-10-18:/discussions/problems/30-hello-flashRobotlegs: Discussion 2018-10-18T16:35:07Ztag:robotlegs.tenderapp.com,2009-10-18:Comment/8459642010-01-13T00:15:50Z2010-01-13T00:15:50ZHello Flash<div><p>You've tried v1.0RC6 from <a href=
"http://github.com/robotlegs/robotlegs-demos-Bundle/downloads">http://github.com/robotlegs/robotlegs-demos-Bundle/downloads</a>
?</p>
<p>What problem did you have getting the example to work?</p></div>Tim Oxleytag:robotlegs.tenderapp.com,2009-10-18:Comment/8459642010-01-13T00:42:25Z2012-04-20T05:31:45ZHello Flash<div><p>stopping here:</p>
<p>TypeError: Error <a href="/discussions/problems/1009" title=
"Discussion #1009">#1009</a>: Cannot access a property or method of
a null object reference.</p>
<pre>
<code>at org.robotlegs.base::EventMap/mapListener()[E:\workspace\flashAS3\external_projects\robotlegs.org\test\src\org\robotlegs\base\EventMap.as:102]
at org.robotlegs.demos.helloflash.view::ReadoutMediator/onRegister()[E:\workspace\flashAS3\external_projects\robotlegs.org\test\src\org\robotlegs\demos\helloflash\view\ReadoutMediator.as:46]
at org.robotlegs.base::MediatorBase/preRegister()[E:\workspace\flashAS3\external_projects\robotlegs.org\test\src\org\robotlegs\base\MediatorBase.as:66]
at org.robotlegs.base::MediatorMap/registerMediator()[E:\workspace\flashAS3\external_projects\robotlegs.org\test\src\org\robotlegs\base\MediatorMap.as:163]
at org.robotlegs.base::MediatorMap/createMediator()[E:\workspace\flashAS3\external_projects\robotlegs.org\test\src\org\robotlegs\base\MediatorMap.as:148]
at org.robotlegs.base::MediatorMap/onViewAdded()[E:\workspace\flashAS3\external_projects\robotlegs.org\test\src\org\robotlegs\base\MediatorMap.as:263]
at flash.display::DisplayObjectContainer/addChild()
at org.robotlegs.demos.helloflash::HelloFlashContext/startup()[E:\workspace\flashAS3\external_projects\robotlegs.org\test\src\org\robotlegs\demos\helloflash\HelloFlashContext.as:60]
at org.robotlegs.mvcs::Context/checkAutoStartup()[E:\workspace\flashAS3\external_projects\robotlegs.org\test\src\org\robotlegs\mvcs\Context.as:213]
at org.robotlegs.mvcs::Context()[E:\workspace\flashAS3\external_projects\robotlegs.org\test\src\org\robotlegs\mvcs\Context.as:77]
at org.robotlegs.demos.helloflash::HelloFlashContext()[E:\workspace\flashAS3\external_projects\robotlegs.org\test\src\org\robotlegs\demos\helloflash\HelloFlashContext.as:41]
at HelloFlash()[E:\workspace\flashAS3\external_projects\robotlegs.org\test\src\HelloFlash.as:36]</code>
</pre>
<p>[SWF]
E:\workspace\flashAS3\external_projects\robotlegs.org\test\bin-debug\HelloFlash.swf
- 49.805 bytes after decompression</p></div>lucas17169tag:robotlegs.tenderapp.com,2009-10-18:Comment/8459642010-01-13T10:39:56Z2010-01-13T10:39:56ZHello Flash<div><p>Hey Lucas,<br>
Maybe it’s the same issue like the one discussed here:<br>
Flex 3 Modules Example - Factory Widget<br>
<a href=
"http://knowledge.robotlegs.org/discussions/problems/19-flex-3-modules-example-factory-widget">
http://knowledge.robotlegs.org/discussions/problems/19-flex-3-modul...</a></p></div>Ondina D.F.tag:robotlegs.tenderapp.com,2009-10-18:Comment/8459642010-01-13T18:12:33Z2010-01-13T18:12:33ZHello Flash<div><p>Hi Lucas,</p>
<p>Apologies if you have done all this already, just
double-checking.</p>
<p>Download the latest Demo Bundle ZIP here:</p>
<p><a href=
"http://github.com/robotlegs/robotlegs-demos-Bundle/zipball/v1.0.0">
http://github.com/robotlegs/robotlegs-demos-Bundle/zipball/v1.0.0</a></p>
<p>And the latest Robotlegs SWC:</p>
<p><a href=
"http://www.robotlegs.org/">http://www.robotlegs.org/</a></p>
<p>Your Flex/Flash Builder project will need to have a "libs"
folder set as a SWC folder as described in:</p>
<p><a href=
"http://wiki.github.com/robotlegs/robotlegs-framework/overview">http://wiki.github.com/robotlegs/robotlegs-framework/overview</a></p>
<p>Finally, make sure that you don't have <em>both</em> the
Robotlegs and SwiftSuspenders SWC files linked to the same project
- I believe this can cause issues.</p>
<p>If, after all that, it's still not working, please let us know
what version of Flash/Flex Builder you are using, and the version
of the Flex SDK that you are compiling against.</p>
<p>Oh dear, I just had a thought.. Are you compiling against the
Robotlegs source code (ie, simply including the Robotlegs source in
the demo projects, instead of linking against the Robotlegs SWC)?
Compiling against the source requires 2 compiler arguments as
described over at:</p>
<p><a href=
"http://github.com/tschneidereit/SwiftSuspenders">http://github.com/tschneidereit/SwiftSuspenders</a></p>
<pre>
-keep-as3-metadata+=Inject
-keep-as3-metadata+=PostConstruct
</pre>
<p>Linking against the SWC will do this for you automagically.
Flex/Flash Builder is a little annoying in that it will create a
"libs" folder for Flex projects, but not for plain ActionScript
projects (you have to create the folder and point at it
manually).</p>
<p>I'm pretty sure using the SWC or including the compiler
arguments will sort out your issue. Let us know how it goes.</p></div>Shaun Smithtag:robotlegs.tenderapp.com,2009-10-18:Comment/8459642010-01-17T03:48:46Z2012-04-20T05:31:46ZHello Flash<div><p>Hi Shaun.</p>
<p>Thank you very much for you kind reply.</p>
<p>My only problem at the end was I didn't know about the compiling
paramiter as I was using both sources (no SWCs).</p>
<p>All I did was, inside flexbuilder 3, right click project root
folder -> properties -> ActionScript Compiler -> the added
the following line inside Additional compiler arguments:</p>
<p>-keep-as3-metadata+=Inject -keep-as3-metadata+=PostConstruct</p>
<p>that was it... up and running.</p>
<p>Cheers</p></div>lucas17169