actionscript

Loading external SWF file issue.

I am building a SWF player which loads external SWF's. Rite Now. I could call the external SWF using URLRequest. but I am getting 2 problems How to run the SWF with the frame rate of the actual SWF movie. How can I know the frameRate of external SWF dynamically from within AS3. I have set a layer of 450px by 350px. How do I scale the...

actionscript: how to read blockly and setup a timeout

I want to do: a write to a socket a block read to read the socket until the response is back, with a timeout. The UI is not freeze at the time ...

get the event when the loaded movieclip is ready in the right frame

Hi, i'm developing an app that use swf to load elements and add properties to the loaded swf. I use SWFLoader to load the movie and on the COMPLETE event i move the loaded MovieClip to a specific frame and then list its DisplayList. I've discovered that if i traverse the list soon it's note loaded. Maybe it's cleaner with code: loader....

Smallest Passive View Source Code (NOT framework) in several languages

I want shortest source code of passive view in several languages Java, C#, PHP, Flash, Objective C and Javascript. I don't want whole frameworks (like javascriptmvc) but tutorial with shortest example possible with complete source code. I can find some searching google in java c# but not for scripting languages, that's quite surprising ...

Flex How To Call A Function With A Variable Number Of Parameters?

Let's Say I Have This Class: package{ import flash.display.Sprite; public class Main extends Sprite{ public function Main(){ trace(getAverage(1,2,3)); trace(getAverage(1,2,3,4)); trace(getAverage(1,2,3,4,5)); } public function getAverage (...numbers) { var total = 0; for (var i = 0; i ...

How to embed timecode when publishing live video and render it when watching?

I've managed to publish video now: ... ns.attachAudio (mic); ns.attachCamera (cam); ns.publish ("name","record"); But without time information. Has anyone managed to do this? ...

Flash upload progress

Hi, I'm making a bandwidth test in flash, and I want to display a progress bar and the current calculated speed. For the download part this is pretty straightforward, but for the upload part it gets a bit trickier. As I've understood the only way to track upload progress is by using FileReference. But as I'm uploading a dynamically gener...

Using the same function for different class instances.

I have a piece of code, that moves an array depending on it's type. If the array is of TypeA objects, it will change TypeA. If it is TypeB it will change TypeB. The issue with the current code is the repeative blocks. private function scrollRight():void { if (SELECTED == CONSTANT) { if (_avatarDat...

AS3 Movieclip not responding to Mouse_Wheel event

I'm creating a container as a MovieClip and adding a mousewheel handler, then adding items to it like so: container = new MovieClip(); addChild( container ); container.addEventListener( MouseEvent.MOUSE_WHEEL, HandleWheel ); container.addChild( item ); // etc. adding more items However the mousewheel is only responding when t...

Flex 4 error handling - how to know which piece of code caused the error

Hi, this question is about how to create useful log information in a .swf that should be send to a serversided log. I have read http://stackoverflow.com/questions/101532/how-to-catch-all-exceptions-in-flex and was very happy about the new UncaughtErrorEvent. But it is not as useful I thought first: You can not get a stack-trace out of...

Selecting Multiple Text Objects.

Consider there are two text field objects: TextField1="texta"; TextField2="textb"; Output: texta textb Now I want to select from "ta" in TextField1 to "tex" in TextField2. By the drag of a mouse. I know that by conventional methods it is not possible? Is there any other way to achieve this? And I need to highlight the text also. Pl...

actionscript: how to customize the loading animation

Hi, I have a swf published into the web, I noticed that Adobe has provided some basic sort of loading animation, as I can see it when I loading the swf(including the library swf, the overall size exceeds 1M bytes). My question how can I add some text into it, like percentage? Or further more, can I write my own "swf loading progress bar"...

ie/firefox and flash: what's the refresh algorithm

Hi, I made a flash and embed it into a webpage. I use the browser to test the flash, an intersting thing, after I upload the flash into the server, and press F5 to refresh the browser, the browser still use the old one, I can't enforce the browser to use the new flash swf file! How can I tell browser to use the new swf? ...

flex URLLoader get Location header

hello, I'm sending POST request using URLLoader and URLRequest with XML data. Then API sends response with redirect page(Location header) and i want to get this URL. How do I catch this response? UPD: Event.COMPLETE in debugger: event = flash.events.Event (@6e1edf9) bubbles = false cancelable = false currentTarget = flash.net.UR...

Show hide multiple datagrid columns in flex

I have a scenario in which i want to show hide multiple datagrid columns at the same time based on a user selection. I can write a click handler for the button and hide all columns one by one but I don't want to do that instead I want to group certain columns and in my click handler want to be able to hide the complete group in one go. I...

How to read excel(2007+ xlsx) sheet using actionscript(AIR)?

How to read excel(2007+ xlsx) sheet using actionscript(AIR)? ...

How to implement click and pause/resume in flash?

Most flash video tutorials have this kind of feature,1st click pauses the video,while 2nd click resumes it. How's that implemented in flash? ...

actionscript: DownloadProgressBar and Flex 4 can't find resource bundle

I am using flex 4 and I want to custom the preloader, but I meet error of DownloadProgressBar. The code: public class MyPreLoader extends DownloadProgressBar { var progress:ProgressBar = new ProgressBar(); Or substitude ProgressBar to Label will produce the same error: Error: Could not find compiled resource bundle 'collectio...

flex MS Project library

Hello all, Is there ActionScript library that works with MPP(MS Office Project)? library that parses MS Project XML? Also please advice me all links that may help me ...

Flash Command Line Interface

I am looking to build a Flash/ActionScript 2 Command Line interface simulator which acts like a Unix/Dos CLI. Does anyone know how to do this, or have a good resource like a tutorial about it. I've been scouring the web for a solution, but only seem to be able to find a tutorial about the effect, not actually having it interactive. A ...