actionscript-3

Modifying File's CreationDate and ModificationDate Properties in Adobe Air

I have written an Air program that mirrors a directory tree. The problem is that the destination folder structure and content need to be identical - right down to the creationDate and modificaitonDate file attributes. How can I change these file attributes using Adobe Air? I'm able to READ them both just fine, but the properties are r...

Display embed images in Flash/Flex Builder

Hi, i'm using image embedding in Flex 4 (the same goes with Flex 3). I have one class with a lot of [Embed(source="../assets/icons/icon1.png")] public static const image:ClasS And i reference them using: <mx:Image source="{imagesResources.image}"/> When i run the application i see the icon but in Flash(Flex) Builder i can't see th...

UIComponent in Swc

In Flash, if i create a custom Movieclip, and compile it to a SWC, i can use it in .fla files (by linking to the .swc).. var mcInstance = new CustomMovieClip(); addChild(mcInstance); All the arrangement of graphics on the custom movieClip's layers is preserved. If i subclass UIComponent and compile to a swc, I can use the custom Clas...

AS3 determine differnce between animated and not-animated gif?

Is there a way in AS3 to determine the difference between animated and not-animated gif? ...

how to add a sharethis button to my flash file?

Hello guys, I have been searching for this solution for some time have not found any good solid solutions. Everything I have seen is either 2 years old and does not work. What I would like to do is use a MC in my flash file to act like a button and when clicked open the sharethis pop up to share this particular video's url. The site AP...

Flash button that links to PDF

Hi Guys, I'm trying to create a button in Flash CS4 with Actionscript3 that links to a PDF file but when I publish the link just takes me to www.example.com I have other links that are working to external sites just this PDF button doesn't work, any ideas would most appreciated. Here is my code. var pdfURL:URLRequest = new URLRequest...

Can two functions in a class be accessed simultaneously in AS3?

In a custom queue, there's a push() and a pop() function. The pop() may be called any time on an Event.COMPLETE, so does this mean that code can be running in push() and pop() simultaneously? If so, is there a way to prevent the code from being run in both functions at the same time? ...

How Adobe AIR program can to index all images on a user's computer?

What is the fastest way for a Adobe AIR program program to index all images on a users' computer? Using Open Source ActionScript-3, MXML Libs and classes. Fastest - Same pc configuration, different time (seconds) To index - get a list of absolute links (like c://bla-bla/file ) and save them into file (index.txt) All images (like JPEG...

How to get folder size in Adobe Air?

How to get folder size in Adobe Air? ...

I want to make the browser fullscreen through my flex website

I have a website which is built totally in flex. I want to make a button, on the click of which the browser becomes fullscreen. I am not talking about a flex fullscreen, by which i mean "Application.application.stage.displayState = StageDisplayState.FULL_SCREEN;" I dont want to use this. The reason, I dont want to use it is, that fla...

Force compile-time linking of all classes in a SWC

Using Flash CS4, I am making a game that has a dozen or so sounds and a couple of music tracks. To cut down on publish/compile time, I have moved the sounds and music into an (external) SWC, which is located in a "Library Path" for the project. This works, but with a caveat... Until before I externalised the assets, I had been dynamical...

Retrieving GET variable via PHP, send to SWF on same script?

Is it possible to retrieve a GET variable within a PHP script and subsequently send the variable data to an SWF on the same script/document? I want the user to select an item on a PHP document and then use a Flash application I am developing to manipulate that data. I know how to load data from a PHP script into an SWF via URLLoader, ...

Regular and Strong tween does not work??

new Tween(Image1movieClip, "y", Strong.easeInOut, Image1movieClip.y, thetargetY, 1.5, true); the following error occurs access of undefined property Strong... however Back and Bounce works here.. ...

[AS3] Calling Php Script with UTF-8 POST variables

AS3 documentation says that Strings in AS3 are in UTF-16 format. There is a textbox on a Flash Clip where user can type some data. When a button is clicked, I want this data to be sent to a php script. I have everything set up, but it seems that the PHP script gets the data in UTF-16 format. The data in the database (which is utf-8) s...

safari 5 resize flash application

Just notice that after updating to Safari 5 (mac) all the flash applications that respond to resize events got sluggish. try: http://www.tutorio.com/media/flash/liquid-demo.html this works great with firefox 3.6.3, Chrome can deal with it fine, although not so fast as Firefox, but new Safari gives a awful experience, distorting all con...

How to search for a file on users file system? ( Adobe Air application)

So we want to seacrch for file like exampl*.ex*mple. We want to search in all users files and folders. I know it will take long, but steel using ONLY AS3\MXML, no native commands, no external programms - only AS3\MXML libs and classes, we can skeep all folders with sise <= 200kb So How to search for a file on users file system? (in A...

Flash player 10 Filereference.save and file extensions

I'm using Filereference.save() to save a XML file. It's working fine with default filename.But is there a way to force a file extension on the saved file? I'm using "untitled.xml" as the default filename, but if the user changes it to say "myfile", it gets saved as "myfile", rather than "myfile.xml". ...

Check if song is buffering in AS3

I have the following piece of code: var song:Sound; var sndChannel:SoundChannel; var context:SoundLoaderContext = new SoundLoaderContext(2000); function songLoad():void { song.load(new URLRequest(songs[selected]),context); sndChannel = song.play(); } Now I want to be able to check if the song is buffering or not. Is there a w...

ActionScript Retrieving Width/Height Of Loader Image

i'm trying to access the width and height of an image that is added to the stage via a custom LoadImage class. the trace results are 0 even though the image displays correctly. what is the problem? //frame script var image:LoadImage = new LoadImage("myImage.jpeg"); addChild(image); trace(image.width); //returns 0 //----------------...

Flash AS3: How do you calculate the width of an image loaded into a movieclip?

I am loading an image into a movie clip via AS3, and what I want to do is center the image inside the movieclip. The problem is that I can't seem to grab the width value of the image being loaded. Below is what I'm doing: imageLoader = new Loader(); imageLoader.load(new URLRequest(event.target.name)); screenBox.screenHolder.addChild(ima...