ActionScript 3.0 :: Load Dynamicaly Named Video Or Photos?
Jan 28, 2009
I have a slide show of either videos or photos. I want the user to be able to click a play button and the video plays or click an arrow and go through a group of photos. The thing that is getting me is the dynamic file loading. I want the user to drop photos or video into a folder and the flash projector file loads them automatically. I don't want naming to be a concern. How would one go about doing this? My intention is to have the user never enter Flash CS3.
I am designing a slideshow comprised of photos, video and some animations. I decided to use Flash because I thought it would offer me more flexibility than other options and because I have some experience coding in ActionScript 2.0 (though oddly very little experience designing swf's).
Here's the thing. In frame 1 I want a video to play. I can make that happen using this code, copied straight from the help:
I want to display photos and load them dynamically.What I have this much done and normally I would just manually add the URL to each button (boring and tedious) and I am learning to import variables and images and all of that...I want to be able to click the thumb to see the actual image:
Main Stage: code: onClipEvent(load){ _xscale=1000;
I used the script below for a slideshow in Macromedia Flash MX2004. The images are in the folder images.xml (and believe me, I checked the names many times). But now the problem: when I load this slideshow, it shows only 3 photos, whereas there are 10 in my folder which I need to show. After the 4th photo I get only black.... it doesn't continue. I cannot figure out what the problem is! Anyone who is more clever out there?
// set random # variables - each must be 0 for first 'while' loop below var randomNum = 0; var randomNumLast = 0;
I am trying to load a variable from a text file named "variable_file.txt" The variable in the file is "var" and I am trying to assign the word "value" When I run the following code:
I'm working on making a site with an xml photo gallery with thumbnails. Right now, I have the gallery working, but I want to add an effect from this site: [URL] When the photos load, the layout resizes according to the photo size. How can I do something like this?
i sort of asked this before but never got a clear responce to it. this is sort of a two part question. one i have a dynamic gallery of images with a small picture that you click on that loads a bigger picture. I would love to be able to just have one photo that loads into the bigger mc and also the small mc. right now what i am doing is making two size photos a small 47x47 and a large141x141. does anyone know how i can use the same photo for both mc's second question. if that works will it make the small photos take forever to load since their sorce is a large photo?
I have a sound Object on the _root timeline that plays when the page loads, that works great. I want to preload it so that the user can see the % of it loaded. Here is my code:
here is my new code that works for PART of my movie. i have two dynamic text boxes, one named "item" and one named "ssnumber" ssnumberNode works fine but itemNode does not. i bolded the parts that i think are relevant to the problems
So I'm making a flash proggy that displays member details for a guild dynamicaly (calling their bio info from a database) and was wondering if it's possible to also call an image dynamicaly as well?I know I could setup a PHP function to display a set image for each member, but that obviously means manualy placing in images and having to update the entire program each time I want to change a picture and thats obviously no good .. so is it possible for actionscript to call in images stored OUTSIDE of the flash program?
Basicly I'm adding dynamicaly sprites and textfields, which i populate from xml, in for loop. I'm building sort of table, so for every sprite, I'm adding new data in textfields.I've loaded xml and passed data to 2 xmllists, both traced and doing fine... Later on I add data from xmllist to array which then I'm looping in for loop.Problem is that from 1st xmllist, 6 out of 7 textfields are visible, 1 can't be found nowhere :/ from the 2nd xmllist only 1 out of 4 are visible...I've tried everything, tracing them returns that they are visible, on good position, filled with text, contrasted color from background.
PS: here is the part probably causing the problems.. for(mojbroj=0;mojbroj < dohvatiosamih2;mojbroj++){if(mojbroj%2){lista.graphics.beginFill(0xdddddd);lista.graphics.drawRect(150,prenesi+(
Is it possible to load libary items from one swf into another?I am trying to load a set of tiles stored in one swf into a tile editor.In the code for the tile editor it adds objects from the libary onto the stage. Is it possible to get the movieclips from another swf?
I'm making a map creator for a tabletop game. The idea is that the map creator would consist of a 48x48 grid and would allow people to drag items onto that grid and save the positional layout of objects like trees and buildings.So I'm working on the very first steps of this and have written the script so far to dynamicaly generate a 48x48 grid and created a test object to be dragged called "follow".
The dynamicaly generated MC draws from the "grid" MC from the library which consists of two layers; the outline of a box and an MC named "grid_bg" which contains a coloured square (set to the same size as the outline). This is all placed into the "container" MC which by default is empty.This part I get working fine.the "follow" mc is set so that it can be dragged on a mouse click.Now the idea is that if a hitTest is run to see if "follow" is in contact with any of the "grid_bg" MC's and if so, run code (i.e. hide or show the grid_bg mc).
This is where I am encountering problems. If I set the hitTest into a layer within the "grid" MC, it only runs the hit test when the movie is first loaded and ignores you dragging and dropping the "follow" mc. If the hitTest is placed into the actions of the "grid_bg" MC and used in conjuction with an IF statement, it seems to act like there is a collision on every box generated.Code to generate the grid:
is it possible to dynamically create variables in actionscript?for example lets say i have some kind of loop and for each itteration of loop i want new variable to be created, or acssed if creatin is not possible. ( tbh i don't need to create them dynamically there is more simple sollution of my problem in real project, am just wandering is it possible )[code]the best i could thought for acessing is filling them in array and acessing it like that.... code works but i am actually trying to make it work without array.[code]
I make my base swf in which I load external swf's. In my base swf I have mp3 player. Everything works fine until I need to load external Video gallery or mmedija.swf. In video gallery I have
I need to load dynamiclly video in flex video player on the web,I'm using standard video player component,when page load a want to load a video in it.I'm not flex programmer
I am testing a flash to run video on my web site [url]... it loads the skin but not the video. I have tested the page in a browser from my computer and it works but it does work when loaded from the web. When I test the page on my computer in internet explorer it gave a blocked content warning but worked when I allowed blocked content.?
I have just entered Falsh and for some strange reason none of my layers are named. Not only that, when I draw a circle for instance and I want to move that circle. I have to move the line and the fill seperate... I think this has something to do with the layers not being named. I will be posting a print screen. Click the link. [URL]