Flex应用程序无法正常工作不需要使用Flash Player的调试版本 [英] Flex app not working without debug version of Flash Player

查看:153
本文介绍了Flex应用程序无法正常工作不需要使用Flash Player的调试版本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

最近,当我试图表明我的工作成果(一些Flex应用程序),以我的老板,我很惊讶,这在我的电脑上运行得很清楚应用程序,我的老板的电脑不正常(显示唯一可见的是一个默认的灰色背景)。试图绝对一切小时后,终于应用程序出现了,当我改变了自己的Flash Player版本的标准之一,调试(无论是诉10.0.22.87)。有谁知道什么可能是这种情况的原因(任何编译器标志或某事)。强迫我的老板安装调试FP是相当不错,但迫使应用程序的最终用户这样做,是不能接受的。

感谢

PS:通过展示我的意思是部署到Tomcat在我的电脑,给我的老板链接到应用程序。我们都用Win XP。此外,当我安装调试FP为Netscape的浏览器和标准FP的IE浏览器(我的电脑)的结果是相同的 - 在Firefox,歌剧,Chrome和灰色背景在IE工作。我编译无论是作为一个调试和作为释放。我使用Flash开发3.0.2 RTM

剥我的应用程序,以某事像这样以后 - 它仍然只能在调试FP

 < XML版本=1.0编码=UTF-8&GT?;
< MX:应用的xmlns:MX =htt​​p://www.adobe.com/2006/mxml
    的xmlns:CA =组件*
    的xmlns:EA =。components.editAreas *
    布局=垂直
    的backgroundColor =黑>

    < MX:帆布ID =头
        verticalScrollPolicy =关
        horizo​​ntalScrollPolicy =关
        的styleName =头
        WIDTH =100%>< / MX:帆布>

    < MX:帆布ID =日程地址搜索Maincontent
        宽度=100%高度=100%
        verticalScrollPolicy =关闭>
    < / MX:帆布>

< / MX:用途>
 

解决方案

同一种问题我面对几天就回来。

我用下面的code

//调用函数 traceDetails(新错误())

私有函数traceDetails(ERR:错误):无效 {         err.getStackTrace() } 对我而言我所用的方法的getStackTrace()这里是要记住的是,的getStackTrace()方法仅适用于Flash调试器而不是Flash播放器。所以,只要我没有Flash调试安装我的应用程序停止运行。

所以,可以做的事 如果你使用任何API调用仅可在Flash调试器,而不是在Flash播放器(如果您发现尝试评论说,网上申请将开始运行)1.检查。 2.解决方法安装Flash调试器版本,无论你正在运行的应用程序或简单地在你的Flash调试器API调用检查(Capabilities.isDebugger)才使用这些API或跳过这些行。

我相信这将解决您的问题。

编码快乐:)

Recently, when I tried to show the results of my work (some Flex app) to my boss, i was quite suprised that application which run perfectly well on my pc, on my boss' pc wasn't displayed properly (the only thing visible was a default grey background). After 3h of trying absolutely everything, finally the app showed up when I changed his Flash Player version from standard one to debug (both was v. 10.0.22.87). Does anyone know what can be the reason of this (any compiler flag or sth). Forcing my boss to installing debug FP was quite ok, but forcing final user of the app to do so is unacceptable.

Thanks

PS: By showing I mean deploying to Tomcat on my pc and giving my boss a link to the app. We both use Win XP. Also when I installed debug FP for Netscape browsers and standard FP for IE (on my pc) the result is the same - working in Firefox, Opera, Chrome and grey background in IE. I've compiled both as a Debug and as a Release. I'm using Flash Develop 3.0.2 RTM

After stripping my app to sth like this - it still works only in debug FP

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
    xmlns:ca="components.*"
    xmlns:ea="components.editAreas.*"
    layout="vertical"
    backgroundColor="black">

    <mx:Canvas id="header"
        verticalScrollPolicy="off"
        horizontalScrollPolicy="off"
        styleName="header"
        width="100%"></mx:Canvas>

    <mx:Canvas id="mainContent"
        width="100%" height="100%"
        verticalScrollPolicy="off">
    </mx:Canvas>

</mx:Application>

解决方案

The same kind of issue i faced few days back.

I was using following code

//Call To The Function traceDetails(new Error())

private function traceDetails(err:Error):void { err.getStackTrace() } On My part i was using the method "getStackTrace()" Here the thing to remember is that getStackTrace() method is only available with Flash Debugger and Not With Flash player. So Wherever i do not have Flash Debugger installed my application stops running.

So Things to do 1. Check if Your using any API call that are only available in Flash Debugger and Not in Flash player(If You found Try commenting that line Application will start running). 2. Work around Install Flash Debugger Version wherever you are running your application or Simply before your Flash Debugger API calls Check if(Capabilities.isDebugger) only then use those API or Skip those lines.

I am sure this will solve your problem

Happy Coding :)

这篇关于Flex应用程序无法正常工作不需要使用Flash Player的调试版本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆