FlashDevelop配置错误

发布于 2025-01-06 04:19:49 字数 1794 浏览 0 评论 0原文

我尝试了一个简单的 Hello World 程序,但控制台只给我这段代码

Running process: C:\Programmi\FlashDevelop\Tools\fdbuild\fdbuild.exe "C:\Documents and Settings\utente\Documenti\Hello world\Hello world.as3proj" -ipc 2f5d48a8-f89e-4dc8-aa99-99e061c45f7f -version "4.6.0; 3.1" -compiler "C:\Programmi\FlashDevelop\Tools\flexsdk" -library "C:\Programmi\FlashDevelop\Library"
Building Hello world
mxmlc -load-config+=obj\HelloworldConfig.xml -debug=true -incremental=true -swf-version=10 -o obj\Helloworld634649421104366338
Starting java as: java.exe
INITIALIZING: Adobe Flex Compiler SHell (fcsh)
Starting new compile.
Loading configuration file C:\Programmi\FlashDevelop\Tools\flexsdk\frameworks\flex-config.xml
Loading configuration file C:\Documents and Settings\utente\Documenti\Hello world\obj\HelloworldConfig.xml
obj\Helloworld634649421104366338 (733 bytes)
(fcsh)Build succeeded
Done(0)
[No debug Flash player connection request]

它必须向我显示 Hello World!我知道配置有问题,但我不知道该怎么办。 我下载了最新版本的FlashDevelop,它使用11.1 flash调试器,以及4.6版本的flex... PS Hello World 类的代码:

package 
{

    import flash.display.Sprite;
    import flash.events.Event;

    public class Main extends Sprite 
    {
        public function Main():void 
        {
            if (stage) init();
            else addEventListener(Event.ADDED_TO_STAGE, init);
        }

        private function init(e:Event = null):void 
        {
            removeEventListener(Event.ADDED_TO_STAGE, init);
            // entry point
        }
    }
}

Main 类的代码:

package 
{

import flash.display.Sprite;

        public class Main extends Sprite 
        {
            public function Main():void 
            {
                trace("Hello World!");
            }
        }
    }

I tried a simple Hello World program, but the console give me only this code

Running process: C:\Programmi\FlashDevelop\Tools\fdbuild\fdbuild.exe "C:\Documents and Settings\utente\Documenti\Hello world\Hello world.as3proj" -ipc 2f5d48a8-f89e-4dc8-aa99-99e061c45f7f -version "4.6.0; 3.1" -compiler "C:\Programmi\FlashDevelop\Tools\flexsdk" -library "C:\Programmi\FlashDevelop\Library"
Building Hello world
mxmlc -load-config+=obj\HelloworldConfig.xml -debug=true -incremental=true -swf-version=10 -o obj\Helloworld634649421104366338
Starting java as: java.exe
INITIALIZING: Adobe Flex Compiler SHell (fcsh)
Starting new compile.
Loading configuration file C:\Programmi\FlashDevelop\Tools\flexsdk\frameworks\flex-config.xml
Loading configuration file C:\Documents and Settings\utente\Documenti\Hello world\obj\HelloworldConfig.xml
obj\Helloworld634649421104366338 (733 bytes)
(fcsh)Build succeeded
Done(0)
[No debug Flash player connection request]

It must show me Hello World! I know there is some problem with configuration, but I don't know what to do.
I downloaded latest version of FlashDevelop, it use 11.1 flash debugger, and the 4.6 version of flex...
Ps the code of the Hello World Class:

package 
{

    import flash.display.Sprite;
    import flash.events.Event;

    public class Main extends Sprite 
    {
        public function Main():void 
        {
            if (stage) init();
            else addEventListener(Event.ADDED_TO_STAGE, init);
        }

        private function init(e:Event = null):void 
        {
            removeEventListener(Event.ADDED_TO_STAGE, init);
            // entry point
        }
    }
}

The code of Main class:

package 
{

import flash.display.Sprite;

        public class Main extends Sprite 
        {
            public function Main():void 
            {
                trace("Hello World!");
            }
        }
    }

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

孤芳又自赏 2025-01-13 04:19:49

您的“Hello world”类在其构造函数和签名中称为“Main”:

 public class Main extends Sprite 
    {
        public function Main():void 

它应该与文件名相同。因此,如果您的类文件名为 HelloWorld.as ,则它将是:

 public class HelloWorld extends Sprite 
    {
        public function HelloWorld():void  

Your "Hello world" class is called "Main" in its constructor and signature:

 public class Main extends Sprite 
    {
        public function Main():void 

It should be the same name as the file name. So if you class file is named HelloWorld.as it would be:

 public class HelloWorld extends Sprite 
    {
        public function HelloWorld():void  
痞味浪人 2025-01-13 04:19:49

您是否在项目资源管理器中选择了 Main 类作为文档类?同一命名空间中只能有一个 Main 类。您的类文件应该是红色(或绿色,我不确定),检查您的项目资源管理器并右键单击您的主类以设置文档类。

Did you select your Main class as your document class in the project explorer ? there should be only one Main class in the same namespace. your class file should be in red ( or green , i'm not sure ) , check your project explorer and right click on your main class to set the document class.

贩梦商人 2025-01-13 04:19:49

flash中有2个地方需要添加flexSDK

  1. 工具=>programmeSetting=>AS3Context=>已安装的Flex SDK=>这里给出SDK的路径

  2. Project=>properties=>sdk=>browse=>这里给出SDK的路径

There are 2 places where we add flexSDK in flash

  1. Tools=>programmeSetting=>AS3Context=>Installed Flex SDK => Give the fath of SDK here

  2. Project=>properties=>sdk=>browse=>Give the fath of SDK here

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文