我有一个带有ant build.xml的Flash Builder项目。我在Eclipse中使用ant文件构建了项目。然后我在FlashDevelop中导入了该项目。我在文件SystemManager.as中收到错误!我的项目名称是loadtest。在项目loadtest.swf中创建了,在其中我可以在项目资源管理器中看到对_loadtest_mx_managers_SystemManager.as的引用。但点击它却什么都不做。
我在线进行了一些搜索,发现SystemManager位于Adobe Flex的mx.manager包中。我正在为此项目使用Flex 4.6 SDK。
我无法理解错误。它与Flex SDK版本有什么关系?或者,这与我在Eclipse中做的Build有什么关系?或者,原因是我在FlashDevelop中打开它而不是Adobe Flash Builder?
这是控制台输出:
Running process: C:\Program Files\FlashDevelop\Tools\fdbuild\fdbuild.exe "D:\Documents\intern\khoa\LOADTEST\loadTestClient\loadTestClient.as3proj" -ipc ac5a2512-1c5d-4dac-913c-de40b01f8d15 -version "4.6.0; 3.1" -compiler "C:\Users\Kajari_G\AppData\Local\FlashDevelop\Apps\flexsdk\4.6.0" -notrace -library "C:\Program Files\FlashDevelop\Library"
Building loadTestClient
mxmlc -load-config+=obj\loadTestClientConfig.xml -incremental=true -swf-version=9 -compatibility-version=3 -locale en_US -default-background-color #FFFFFF -o obj\loadTestClient635446913648564685
Incremental compile of 1
Loading configuration file C:\Users\Kajari_G\AppData\Local\FlashDevelop\Apps\flexsdk\4.6.0\frameworks\flex-config.xml
Loading configuration file D:\Documents\intern\khoa\LOADTEST\loadTestClient\obj\loadTestClientConfig.xml
Updated: D:\Documents\intern\khoa\LOADTEST\loadTestClient\src\functions.as
Files changed: 1 Files affected: 175
_loadtest_mx_managers_SystemManager.as(95): col: 40 Error: Type was not found or was not a compile-time constant: Array.
private var _allowDomainParameters:Vector.<Array>;
^
_loadtest_mx_managers_SystemManager.as(100): col: 48 Error: Type was not found or was not a compile-time constant: Array.
private var _allowInsecureDomainParameters:Vector.<Array>;
^
_loadtest_mx_managers_SystemManager.as(131): col: 42 Error: Access of undefined property Array.
_allowDomainParameters = new Vector.<Array>();
^
_loadtest_mx_managers_SystemManager.as(155): col: 50 Error: Access of undefined property Array.
_allowInsecureDomainParameters = new Vector.<Array>();
^
_loadtest_mx_managers_SystemManager.as(7): col: 25 Error: Definition flash.text.engine:TextBlock could not be found.
import flash.text.engine.TextBlock;
^
_loadtest_mx_managers_SystemManager.as(8): col: 25 Error: Definition flash.text.engine:TextLine could not be found.
import flash.text.engine.TextLine;
^
Build halted with errors (fcsh).
任何帮助表示赞赏!谢谢!
答案 0 :(得分:0)
解决!我不得不将目标Flex SDK更改为3.6a。以前是Flex SDK 4.6。
感谢以下论坛帖子:
http://www.flashdevelop.org/community/viewtopic.php?f=13&t=8960&view=next
答案 1 :(得分:0)
这是因为您的项目无法找到mx.manager.SystemManager的问题。您选择的sdk版本不支持。您可以切换您的sdk或包含playerglobal.swc。选择取决于你。