ActionScript 2.0 :: Dynamically Creating MCs To Load External JPGs Into?

Nov 16, 2004

I'm trying to create a slideshow that loads pics (jpg) from an external folder ("pics/") into dynamically created MCs.What I want is for the script to detect how many pics are in the folder (for future changes), create as many instances of the MC, and load the pics into each one. The MCs will need to take the W and H of the pics, and line up next to each other.This last part is not as important, I'm just wondering how to determine the number of pics in the folder. Do I need XML or will AS 1.0 or 2.0 do this?

View 1 Replies


Similar Posts:


ActionScript 2.0 :: Dynamically Creating MCs To Load External JPGs Into

Nov 16, 2004

I'm trying to create a slideshow that loads pics (jpg) from an external folder ("pics/") into dynamically created MCs.What I want is for the script to detect how many pics are in the folder (for future changes), create as many instances of the MC, and load the pics into each one. The MCs will need to take the W and H of the pics, and line up next to each other. This last part is not as important, I'm just wondering how to determine the number of pics in the folder. Do I need XML or will AS 1.0 or 2.0 do this?

View 1 Replies

ActionScript 3.0 :: Dynamically Loading External Jpgs Into A Dynamically Created MC?

May 18, 2009

Essentially, I've got a MC container that's created dynamically based off an XML file (basically for every <title></title> I've got, it makes a new "card"). Now within the context of each <title></title> grouping I've got <imgs></imgs> in which I specify the path to images that are related.All of that works perfectly, save for the external jpg files actually appearing on the stage. The MC I add them to does, but the external image doesn't.My problem is- I can't add the external images until they're completely loaded (or so it appears). The thumbnail BG I use is blank. So I know for a fact that the thumbnail BG isn't occluding the loaded thumbnails.

View 2 Replies

ActionScript 2.0 :: Load Multiple Jpgs Dynamically?

Oct 18, 2003

I am new to Flash, and I am taking the tutorialon loding jpegs dynamically. My question is canyou alter the script, and with the click of the samebutton load next jpg, then next etc

View 4 Replies

ActionScript 2.0 :: Dynamically Load Jpgs Randomly In FLA?

Sep 25, 2003

I wont to dynamically load jpgs randomly in my FLA.

View 5 Replies

ActionScript 2.0 :: Load External Jpgs Into A Swf?

Jan 19, 2004

how can you load external Jpgs into a swf instead of loading them and compiling the swf. so that they appear in the cache. Whats the function to do this, or is there a tut?

View 1 Replies

ActionScript 3.0 :: Load Multiple External Jpgs?

Jul 11, 2009

I'm trying to go through a for loop, create a movieclip for each database entry, add the image by url stored. The problem is the code I have only does the last image. I know it's because something is not incrementing and they all have the same name. Do I need to increment the name of my loader?[code]...

View 11 Replies

ActionScript 3.0 :: Dynamically Creating MovieClip From Library With External Class

Jun 10, 2010

I am making a Thumbnail class which is part of my Photo Gallery Package that I am building with the intent of automatically generating my thumbnails. I do not want to limit myself to just AS3 animations, I would also like the ability to use timeline animations. I have a system using "in" and "out" for frame labels which I find very efficient and I get stuff done quickly. So I created the thumbnails holder MovieClip with the animations and have it linked in my Library, however, when I try to pass it to my Thumbnail Class, I only get one instance and I need to create several instances.

Document Class
ActionScript Code:
var thumbCont:mcThumb = new mcThumb();
thumbNails = new Thumbnails(thumbCont);

Thumbnails Class
ActionScript Code:
var thumbContainer:MovieClip;
public function Thumbnails(thumbCont:MovieClip,) {
thumbContainer = thumbCont;
}private function createThumbs():void {
for (var i:int = 0; i < aThumbs.length; i++) {
[Code] .....

I eliminated most of the additional stuff. What this does is that it doesn't create several thumbContainers, rather it just uses the one. So how would I be able to generate several of them? I can obviously create an Array with them and create them in my document class, but if I can avoid that and have my thumbnail class do it by itself, that would be perfect.

View 2 Replies

ActionScript 1/2 :: Smooth Dynamically Loaded Jpgs?

May 12, 2009

I'm setting up an online picture gallery. I'm trying to make it easy for the client to insert specific images, dynamically loaded, have them appear at 63 percent. If the user clicks on one, it enlarges to 100 percent. Trouble is, when the image is at 63 percent, it is not smooth and looks terrible,All the BitmapData class solutions posted online work for individual images. But I can't figure out how to automate the process in a for loop. At this point I'm not even worrying about the enlarging. I just want the images to load at 63 percent and look smooth.Below is the code for two images. Later I'll increase this to 25.

On the stage are two colored rectangle movie clips: toon1 and toon2. I want the dynamically loaded jpegs to load inside them. The client will manually edit the last lines whenever she feels like it, to choose which images to load.What I need is an elegant AS2 solution in which any dynamically loaded jpeg will be smoothed.

for (i=1; i<=2; i++) {  this["toon"+i].createEmptyMovieClip("cartoon",this.getNextHighestDept h());  this["toon"+i].cartoon._xscale = this["toon"+i].cartoon._yscale=63; 

[code].....

View 5 Replies

ActionScript 2.0 :: Preloader For Dynamically Loading Jpgs?

Jul 28, 2003

i just need a preloader for my dynamically loading jpgs.

fyi, i don't need buttons or anything for this...it's a very simple slideshow where the images come in every 100 frames...that's it.

does anyone know what code i should put it so that my images will preload at the beginning so the slideshow doesn't stutter?

View 3 Replies

ActionScript 2.0 :: Loading Jpgs Via URL Into A Flash Dynamically?

May 24, 2002

I would like to have a flash movie load a picture as the background image of a symbol or otherwise be viewable. The picture would be referenced via a URL on another site.Example. putting in a URL ending in '.jpg' would make another object show the pic from that URL.

View 8 Replies

ActionScript 2.0 :: Loading Multiple Jpgs Dynamically?

Oct 18, 2003

loding jpegs dynamically. My question is can you alter the script, and with the click of the same button load next jpg, then next etc?

View 4 Replies

Actionscript 2.0 :: Creating A Gallery Of Images/sound Clips Which Load Dynamically?

Jan 18, 2009

So I've been working on a Flash-based web portfolio for my sound design work, and I'm creating a gallery of images/sound clips which load dynamically (that way I don't need to recompress the swf file every time I add/remove a production). I'm having trouble with checking to see if files exist; for example, I want to check if a sound file exists, and if it does, set the alpha property of a symbol to 100%, and if it doesn't, set the alpha property of that symbol to 25%.

The code I'm using works fine when I test the file locally, but as soon as I upload the file and test it, the movie responds as if a file exists even when it doesn't, and I can't figure out why.

[Code]...

View 1 Replies

ActionScript 2.0 :: Center Dynamically Loaded JPGs Of Dif Sizes?

Apr 20, 2006

I've read a few of the other threads on this subject but still had no luck. I'm loading jpgs via an xml file and the pics are all diffrent sizes. I'm trying to figure out how to center the image once loaded, but am running into brick wall after brick wall.[code]...

View 1 Replies

ActionScript 2.0 :: Loading Multiple Jpgs Dynamically With LoadMovie And MovieClipLoader

Dec 13, 2005

I'm loading multiple instances of the same jpg dynamically to my swf. It works just fine locally, but when I upload it, it only executes the first loading code it encounters in the timeline. I was doing things fairly complexly with 'for' loops and dynamic name generation and stuff, but I've stripped it down to the basics in an effort to get this to work.

Here's some code:

loadMovie('1.jpg', mc1.empty_mc);
loadMovie('1.jpg', mc2.empty_mc);
mcLoader.loadClip('1.jpg', mc3.empty_mc);
mcLoader.loadClip('1.jpg', mc4.empty_mc);
mcLoader.loadClip('1.jpg', mc5.empty_mc);

as you can see, I'm using two different methods of loading the jpgs, just in an effort to pin down exactly what is going on. Locally, they all load fine. When I upload to the server, only the first instance of the loading code is run (so mc1 will get its jpg, but the rest won't). I've tried to swap the order, place the loading code in different areas, try to load different jpgs into each empty mc, but nothing works except that first instance flash gets to in the timeline.

The swf and jpgs are all in the same folder, both locally and on the server. The server the swf is hosted on is Windows 2003 box if that matters. I tried uploading it to a different windows box and got the same problem.

View 2 Replies

ActionScript 3.0 :: Creating A Button To Load External SWF?

Mar 5, 2011

I have a flash website that loads rather slowly, presumably because it is composed of a single .swf file, so I want to break that down into several. So how do I create a button that loads an external swf on top of the existing movie?

So far I have this which I pulled from {URL]

Code:
//This creates a new instance of the loader object.
var my_Loader:Loader = new Loader();
//This creates a new instance of the URLRequest object that contains the
//path to the external SWF.

[Code].....

View 1 Replies

ActionScript 3.0 :: Creating If / Then Statement - Load An External XML File

Apr 6, 2011

I'm using a movieclip to load an external XML file. In the XML I have a series of variables:

[Code]..

View 26 Replies

ActionScript 2.0 :: Jpgs Won't Load?

Dec 26, 2003

I followed the instructions in the tutorial "photo gallery" and for some reason my jpgs won't load.I pulled one of the images from the tutorial into the directory that I was telling my pics to be taken from and they work. So it isn't the path.All of the nature photos loa without fail, but my jpgs won't?

View 4 Replies

ActionScript 2.0 :: Loading The External Jpgs?

Jan 19, 2004

how can you load external Jpgs into a swf instead of loading them and compiling the swf. so that they appear in the cache.

View 1 Replies

ActionScript 3.0 :: Load An External Class Dynamically?

Oct 23, 2010

No swf involved, just loading a .as file

View 7 Replies

ActionScript 3.0 :: Load Jpgs Into My Swf At Runtime?

Oct 28, 2009

I'm trying to load jpgs into my swf at runtime but they always come out black and there is no image. Could it be that my files are too big?

View 1 Replies

ActionScript 3.0 :: Create An Array Of External JPGs?

Aug 12, 2009

So what I want to do is load up external JPGs into an Array of MovieClips, and then go to the main onEnterFrame function. [code]...

View 4 Replies

IDE :: External Jpgs & Exporting Pixel Data?

Jun 24, 2009

I wondering if with flash would be able to load in an external jpg file and then export the pixel data into a php application to rebuild the image?My concern is when an application loads an external resource it is just that, external and not local and therefore when I come to grab the pixel data will it grab the external resource in this case the image I've placed inside a movie clip?

View 3 Replies

ActionScript 2.0 :: Preload .jpgs From External Array?

Nov 10, 2003

I am building a portfolio disk with the awesome photo gallery AS from here. This will be run from a cd and I want to preload the images in the arrays to keep everything smoooooth. I am building on current machine. When I tested a disc image on an older machine the transitions were slooooow. I figure preloading would defeat this. Is there AS to accomplish this or is it something simple like hiding the images somewhere on the timeline and using a normal preloader?

View 3 Replies

ActionScript 2.0 :: Loading External Jpgs And Resize?

Apr 8, 2004

I want to know how can I load external jpgs into a "frame" and depending on the size of the jpg resize this "frame" as you can see here:

View 9 Replies

ActionScript 2.0 :: [MX2004] External JPGs & LoadMovie()?

Mar 12, 2005

I have 100 mc's loading external thumbnail jpgs via loadMovie(). I need a preloader of some sort to show the status of the thumbnails. The problem is that each of the mc's are loading JPG individually and I am not sure of how to combine their loading statuses into a preloader. The other option I had planned to use was to make one thumbnail larger in file size than the others so that it would load last and therefore I could use some onload function for this particular thumbnail, but I do not know what would be best to use in this case.

View 1 Replies

ActionScript 3.0 :: Load A Swf That Is Dynamically Built, With An External Preloader?

Feb 10, 2010

Im trying to load an swf that is dynamically built, with an external preloader I built. The actionscript used is as follows:

var l:Loader = new Loader();
l.contentLoaderInfo.addEventListener(ProgressEvent .PROGRESS, loop);
l.contentLoaderInfo.addEventListener(Event.COMPLET E, done);[code].....

I get the following error: TypeError: Error #1009: Cannot access a property or method of a null object reference. at com.cool::Cool()

View 3 Replies

ActionScript 3.0 :: Load Text Dynamically With An External.txt File?

Sep 23, 2009

I'm trying to load text dynamically with an external.txt file. This works fine. The problem is formatting the test. For some reason, loading the text from an external file has complicated things a bit. Nothing formats the way I want it to...the text size doesn't even change.When I started with this movie, I had my copy in a string in the AS code and was able to format the text color, font, size, textbox width and height as well. No problems. That's issue #1.

Issue #2 : you'll notice I'm using the greensock classes to animate a movieclip (also has text in it). I'm using a mask layer over the MC. When I try running the movie, my animation works fine, but none of my text loads...and it doesn't matter if it's a text string in the code or an external text doc. I was told that I need to embed the font..which I have the code for, as you'll see below..but it did nothing.

Code:
import gs.*;
import gs.easing.*
import gs.utils.TransformMatrixProxy;

[code]....

View 6 Replies

ActionScript 3.0 :: Dynamically Load Multiple External Images?

Aug 26, 2010

I'm not quite conversant with classes and loading external pictures so be patient My intention is the following: a sort of slide show which dynamically loads all pictures of a certain directory and displays them one after the other. To do so I want to get the number of images of a certain diretory (img) by using a PHP script (done), then the PHP-Script sends the data to the Flash file (done) which stores it in a variable (done). I've created a class called PHPLoading for doing this (finally it creates an array which stores the links dynamically created (pictures are named 0.jpg, 1.jpg, [code]...

View 6 Replies

ActionScript 2.0 :: Dynamically Load External Swf Movie Into Its Object?

Mar 9, 2012

I have a problem loading a swf object into an existing object. Everything works fine within the parent swf object, but I don't know how to make the whole object dynamically so I can call the parent object with a URL flash variable (or something like that). [code]...

View 6 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved