有没有一种方法来检查从ActionScript循环参数的值? [英] Is there a way to check the value of the loop parameter from ActionScript?

查看:157
本文介绍了有没有一种方法来检查从ActionScript循环参数的值?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有许多参数,可以添加到对象嵌入标签嵌入Flash视频。大多数上市这里。他们中的一些可以访问/通过ActionScript编程方式改变(例如< PARAM NAME =规模与GT; 可以通过以下方式访问在Stage.scaleMode )。

There are a number of parameters that can be added to object and embed tags to embed flash videos. Most are listed here. Some of them can be accessed/changed programmatically via ActionScript (e.g. <param name="scale"> can be accessed via stage.scaleMode).

能否的参数进行访问的循环值/变化?

Can the value for the loop parameter be accessed/changed?

编辑补充:我知道FlashVars的,这不是我在问什么

推荐答案

一般网的共识是,不,你不能从内部闪存访问除Flash变量/电影等参数。

The general net consensus is that no, you can not access parameters other than flashvars/movie from inside Flash.

不过,您可以访问参数,在某些浏览器,至少从JavaScript - 当然,你可以Flash和JavaScript之间的使用外部接口

However, you can access the parameters, in some browsers at least, from JavaScript - and of course you can interface between Flash and JavaScript using an external.

沿的线条也许一个JavaScript程序:

Perhaps a javascript routine along the lines of:

function getParam(paramName) {
    return $('#flashid param[name=' + paramName + ']').val();
}

随着闪光灯的方法:

Along with a method in Flash:

import flash.external.ExternalInterface;

function getParam(paramName:String):String {
    return String(ExternalInterface.call("getParam", paramName));
}

显然,确保脚本访问是对SWF和对象/嵌入启用。

Obviously ensuring script access is enabled on the SWF and the object/embed.

这篇关于有没有一种方法来检查从ActionScript循环参数的值?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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