Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash




How Do I Close Dynamically Loaded Jpegs?



i have dynamically loaded jpeg , but now how do i make it dissappear when its clicked on?



KirupaForum > Flash > Flash 8 (and earlier) > Flash MX
Posted on: 10-24-2003, 02:47 PM


View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread

How Do I Close Dynamically Loaded Jpegs?
i have dynamically loaded jpeg , but now how do i make it dissappear when its clicked on?

Help With Dynamically Loaded Jpegs
I am using this tutorial to load jpegs into container mc's
http://www.kirupa.com/developer/mx/loading.htm

The images show up on computers with flash player 8, but not on computers with flash player 7 or below.
any idea why?
and how do i make them show up in flash player 7.
thanks

Dynamically Loaded Jpegs
I loaded a picture dynamically but it looks very sharp and stands out too much. Is there a way that i could put a border around the picture (probably a mask) to help it to blend in more

heres the code i used to genreate the jpeg.

Quote:




_root.createEmptyMovieClip("imageHolder1", 200);
imageHolder1._x = 160;
imageHolder1._y = 55;
loadMovie("digicel.jpg", "imageHolder1");
stop();

Properties On Jpegs Loaded Dynamically
Hello,

Is there a way to change the properties of a jpeg using loadMovie()? The properties I want to change are the width and height of the picture.

For example, I am loading a picture using this stmt.

loadMovie("Cinema-"+whichPic+".jpg", "square");

where whichPic is simply an integer number. Is there a way to duplicate the mc square and then resize it so that it serves as a thumbnail?

Thanks for your help,
Fabocp

Preloading Dynamically Loaded JPEGs?
I have three movie clips that each dynamically load a JPEG...i have the code that loads the JPEGs placed on one of the first frames...the problem is that there is a pause or delay...until the JPEGs are loaded...which leaves the screen with a void...and makes you think there is no content...how can I put a preloader that will show the user that the images are being loaded?

thanks,
diabolicalbutter

Need To Scale Dynamically Loaded Jpegs
Hi,

I'm dynamically loading movies (jpegs) and attaching them to another movie one at a time. Since the jpegs are all different sizes, is there a script I can use to scale all of them to the size of the object that I'm attaching them too? I've been trying to use:

code:
_root.onEnterFrame = function() {
loadMovie("../images/image"+whichPic+".jpg", "screen");
this.screen["image"+whichPic+".jpg"]._x = screen._x;


with no success. The image (there's only one at the moment) appears but it's way too big and needs to be scaled to the "screen" object it's attached to.


TIA,
aaroneousmonk

Dynamically Loaded Jpegs---PROBLEMS
Hey guys
I'm loading JPEGs dynamically from a DB using PHP and LoadVars in FMX. I get the images to load perfectly. but i'm having a problem moving them into proper placement.

Goal= I'm trying to load all the images into a specific area and have them dynamically resized so they all fit within the area (another MC).
I'm creating empty movie clips and loading the jpegs into them.


Problem = The created MCs wont MOVE OR RESIZE!! They'll place properly, but no animation!

i'm using this function for motion:

MovieClip.prototype.slideTo = function(x, y, speed) {
//set up targets and speed variable
this.targetX = x;
this.targetY = y;
this.speed = speed;
//create onEnterFrame function
this.onEnterFrame = function() {
//take care of motion
this._x += (this.targetX-this._x)/this.speed;
this._y += (this.targetY-this._y)/this.speed;
// check if near target
if (Math.abs(this.targetX-this._x)<0.2 && Math.abs(this.targetY-this.y)<0.2) {
this._x = this.targetX;
this._y = this.targetY;
}
};
};
//
//
//and this to place the photos
//

function getPhotos(List) {
x = 0;
for (var item in List) {
//loop thru and get images, place them in
myitem = List[item].filename;
mypic = _root.createEmptyMovieClip("image"+x, x++);
loadMovie("thumbs50/"+myitem+".jpg", "image"+x);
trace (_level0.mypic._width);
_root["image"+x]._width = 100;
_root["image"+x]._height = 100;
_root["image"+x].slideTo(someX, someY,someSPEED);

}
}

where someY, someX, someSPEED, will be generated by another script.

Help!
my code is a little sloppy, its still in the works....
i may be overlooking something small, please help.

You can look at what i mean about the photo placement here, I'm trying to recreate this in flash MX: Distortion Photography
(there's a JS error on the page, click thru it).



Thanks in Advance
Jbot

Problem With Dynamically Loaded Jpegs
i've created a site for a photographer using dynamically loading jpg's to minimize file size. The site works fine on most of the computers i've checked it on, but on some computers, especially macs, the WHOLE site goes down when the first jpg unloads...
does flash player 6 deal with loading and unloading jpegs in the same way as 7? might this be my problem?

Resizing Dynamically Loaded Jpegs
Hi,
I am loading JPEGs into an MC called pictureHolderMC using "loadMovie" without a problem. But, the JPEGs are different sizes and I need them to be a constant width (100 pixels) so I am using the code below to set this:

Code:
_root.pictureHolder._width = 100;
But when I add this code the JPEG disappears from "pictureHolderMC". I know that "pictureHolderMC" is still there as I put a background colour block in it which still shows up, but without the JPEG.
Ultimately, I will write a function that also sets the "_height" property in proportion, but I need to get the basics of controlling the size to work first.
Any suggestions as to how o achieve this would be much appreciated.

Centering Dynamically Loaded JPEGs
I know this has been asked a million times- and trust me, I tried everything I could find in these forums, but nothing seems to be working right for me. I have a gallery that dynamically loads JPEGs from an XML file. It uses next/previous buttons to flip through the code.

The main code is:

ActionScript Code:
function loadXML(loaded) {
    if (loaded) {
        xmlNode = this.firstChild;
        image = [];
        description = [];
        total = xmlNode.childNodes.length;
        for (i=0; i<total; i++) {
            image[i] = xmlNode.childNodes[i].childNodes[0].firstChild.nodeValue;
            description[i] = xmlNode.childNodes[i].childNodes[1].firstChild.nodeValue;
        }
        firstImage();
    } else {
        content = "file not loaded!";
    }
}
xmlData = new XML();
xmlData.ignoreWhite = true;
xmlData.onLoad = loadXML;
xmlData.load("images.xml");
// ///////////////////////////////////
listen = new Object();
listen.onKeyDown = function() {
    if (Key.getCode() == Key.LEFT) {
        prevImage();
    } else if (Key.getCode() == Key.RIGHT) {
        nextImage();
    }
};
Key.addListener(listen);
previous_btn.onRelease = function() {
    prevImage();
};
next_btn.onRelease = function() {
    nextImage();
};
// ///////////////////////////////////
p = 0;
this.onEnterFrame = function() {
    filesize = picture.getBytesTotal();
    loaded = picture.getBytesLoaded();
    preloader._visible = true;
    if (loaded != filesize) {
        preloader.preload_bar._xscale = 100*loaded/filesize;
    } else {
        preloader._visible = false;
        if (picture._alpha<100) {
            picture._alpha += 10;
        }
    }
};
function nextImage() {
    if (p<(total-1)) {
        p++;
        if (loaded == filesize) {
            picture._alpha = 0;
            picture.loadMovie(image[p], 1);
            desc_txt.text = description[p];
            picture_num();
        }
    }
}
function prevImage() {
    if (p>0) {
        p--;
        picture._alpha = 0;
        picture.loadMovie(image[p], 1);
        desc_txt.text = description[p];
        picture_num();
    }
}
function firstImage() {
    if (loaded == filesize) {
        picture._alpha = 0;
        picture.loadMovie(image[0], 1);
        desc_txt.text = description[0];
        picture_num();
    }
}
function picture_num() {
    current_pos = p+1;
    pos_txt.text = current_pos+" / "+total;
}

I tried using the following statement in the actually MC called picture

ActionScript Code:
onClipEvent(enterFrame){
    if (!this.loaded && this.getBytesLoaded() > 0 && this.getBytesLoaded() == this.getBytesTotal()){
        this._x -= this._width/2;
        this._y -= this._height/2;
        this.loaded = true
    }
}
It works for the first image and then does not update when the image changes. I also tried moving minor variations of that code around in the main code blurb above, but it does nothing there. Is there something I can add for it to update on change?

Thanks!

Getbytesloaded, Dynamically Loaded Jpegs Etc.
hi all
i have searched the site and read all the links on dynamically loaded jpegs listed in cyanblues post above, but i'm still not understanding where i'm going wrong. i'd be grateful for advice:

here's what i'm doing, 1 & 2 work fine but 3 is where it all stop working as I would expect:


1. duplicate the original:
------------------------

ActionScript Code:
for (Mainnumber=0; Main number<(NumberOfItems); Mainnumber++) {
        this.originalMain.duplicateMovieClip("main" + Mainnumber, Mainnumber);
        _root["main" + Mainnumber]._y = (Mainnumber * 75) + 1;
}

2. load jpeg to the symbol: (this script attached to the originalMain)
------------------------

ActionScript Code:
onClipEvent (load) {

    myname = this._name;
    myMainnumber = myname.charat(4);
    barcodenum = _parent.items[myMainnumber];
    mainpicfilename = "mainphotos/"+barcodenum+".jpg";
    loadMovie(mainpicfilename, this.mainphotos);

}
3. to check the bytes loaded, i am trying this on the next frame
----------------------------------------------

(this just to debug; i would actually have a while {} loop waiting for them all to returnt that they are loaded)

to check just one of the images, inside main1, main2 or main3:

ActionScript Code:
trace(_root.TargetMC.main1.mainphotos.getBytesTotal());
trace(_root.TargetMC.main2.mainphotos.getBytesTotal());
trace(_root.TargetMC.main3.mainphotos.getBytesTotal());

but these always returns a value of 12 -- it must be the byte size of the symbol itself not the jpeg (which is about 100k), even if i loop it 100 times to simulate some wait time....

so my question is how do i do getBytesTotal() (and of course getBytesLoaded() ) on the jpeg so that I can evaluate the difference...?

does it just not work on dynamically loaded jpegs?

i would be grateful if someone could explain the exact procedure for a. dynamically loading the jpegs; b. checking that they are loaded -- i thought i knew what i was doing but, first, it didn't work and second, when i read through the posts mentioned above it really threw me.....

thanks.......

Problem With Dynamically-loaded Jpegs
i recently completed a site that dynamically loads jpegs and when viewed in a browser, the pics are SO blurry. i'm confused because i have another site, set up the same way, and the pics aren't blurry at all.
the pics for the two sites were taken by two different digital cameras, but i optimize them the same way in photoshop.

here's blurry (go to the PHOTOS section):
http://www.thegaragebar.net

here's not blurry (go to FOR RENT section):
http://www.urbanrestorationsproject.com

what am i doing wrong with the first site?

Dynamically Loaded Jpegs And OnEvent Handlers
i've got a movie that attaches a blank mc on the stage via attachMovie, and then loads a jpeg into it via loadMovie. The problem is, once this is done the image will not respond to user input (i.e. onRelease, onRollOver don't work) Can anyone explain why this happens?

Crossfades On Dynamically Loaded Jpegs - Any Tutes Out There
Hi. I am working on a click through type slide show (photographers site). All the images are being loaded in dynamically. At present the images are fading out- then fading in, done by actionscript. All works fine. However what I really need is to cross fade the images. I have searched the forums but all to no avail although the question of crossfades did come up a few times but with no answers. I had a look at the source code that was available from www.whatdoiknow.org/archives.shtml. However I need the images to be click though not automatic and i don't know enough as to how to alter that code. What I did manage to pull from the code is that I might need to create 2 mc containers and load the images into varying levels. That is my theory but I have no idea how to implement this. If I am somewhere warm with this, or if any one can help with code, or if anyone can point me to a tutorial I would be very very very grateful.

thanks in advance

Preload Dynamically Loaded Jpegs And Fade
I have been researching the forums on information to do this. To be quite honest, I'm still somewhat of a Newb so I'm having difficulty piecing everything together. Here is what I am looking to do!

I would like to preload 10 dynamic jpegs into a movieClip. I want the getBytesTotal function active, showing the progress in the swf preload. I don't want the movie to start playing until the jpegs are loaded. Once they are loaded, I would like them to fade from one another, and loop.

I was going to simply program it within flash, but that's a heavy file, I do know how to simply load dynamic images, but I have no idea how to interact it with a preloader and AS to make them fade.

Any help would be appreciated, if anyone is willing to post a sample file, I usually can figure it out from there.

Thanks

Preload Dynamically Loaded Jpegs And Fade
I have been researching the forums on information to do this. To be quite honest, I'm still somewhat of a Newb so I'm having difficulty piecing everything together. Here is what I am looking to do!

I would like to preload 10 dynamic jpegs into a movieClip. I want the getBytesTotal function active, showing the progress in the swf preload. I don't want the movie to start playing until the jpegs are loaded. Once they are loaded, I would like them to fade from one another, and loop.

I was going to simply program it within flash, but that's a heavy file, I do know how to simply load dynamic images, but I have no idea how to interact it with a preloader and AS to make them fade.

Any help would be appreciated, if anyone is willing to post a sample file, I usually can figure it out from there.

Thanks

Problem With Preloader For Dynamically Loaded Jpegs
I use this code to display the progress of the jpeg im loading dynamically into my empty movieclip, bildholder.


bytes_loaded = Math.round(bildholder.getBytesLoaded());
bytes_total = Math.round(bildholder.getBytesTotal());
getPercent = bytes_loaded/bytes_total;
loadpic = "_loading_product "+Math.round(getPercent*100)+" % loaded";
if (bytes_loaded >= bytes_total) {
gotoAndPlay("done");
}

The problem is that I cant get the line:
bytes_total = Math.round(bildholder.getBytesTotal());

to work. It seems that Flash have a problem getting the TotalBytes for a dynamically jpeg.

When i set bytes_loaded to a fix number, say 5000, then the preloader works but not wgen I use the command .getBytesTotal()

Can anyone tell me why or how I can solve this problem.

Problem With Preloader For Dynamically Loaded Jpegs
I use this code to display the progress of the jpeg im loading dynamically into my empty movieclip, bildholder.


bytes_loaded = Math.round(bildholder.getBytesLoaded());
bytes_total = Math.round(bildholder.getBytesTotal());
getPercent = bytes_loaded/bytes_total;
loadpic = "_loading_product "+Math.round(getPercent*100)+" % loaded";
if (bytes_loaded >= bytes_total) {
gotoAndPlay("done");
}

The problem is that I cant get the line:
bytes_total = Math.round(bildholder.getBytesTotal());

to work. It seems that Flash have a problem getting the TotalBytes for a dynamically jpeg.

When i set bytes_loaded to a fix number, say 5000, then the preloader works but not wgen I use the command .getBytesTotal()

Can anyone tell me why or how I can solve this problem.

Seamless Playback Of External, Dynamically-Loaded JPEGs
Hi Guys,

   I've been at this for a while, and I am afraid I am still quite the newbie when it comes to Flash.  

   I want to use Flash as the GUI for a (near real-time) screen capture viewer.  I want a user to be able to transmit screen captures of their screen on one end, and on the other, have someone with my Flash movie in their browser be able to see the captures as they are coming from the other person's machine.  I am writing an app in Delphi to do the captures and broadcasting.  Currently, the images are saved on a server, the server from which I will be pulling these JPEGs and placing them dynamically in the Flash piece.

   Basically, all I want is some Flash that will read in a series of numbered images (image_01.jpg, image_02.jpg, etc.), and display them, one at a time, without delays inbetween and without flicker of any kind - indefinitely.  I have read of preloading images off stage and what not, but I am still not implementing this right.  And also, I want to understand how to do it correctly and efficiently, not just make it work any which way.

   I am thinking there is going to have to be some sort of delay BEFORE the first image is shown, to build up a decent amount of images to pull from on the server.  

   Can anyone out there give me some feedback on this?  Some code that can get me to where I am trying to go?  

   Thanks,

     -Tony

Movie Clip With Dynamically Loaded JPEGs Not Responding To Mouse Clicks
I have a movie clip called pictureframe that I am loading JPEGs into sequentially with a movieClipLoader. I want to be able to click on each JPEG and go to a different web site, but it's not working. The MC is not accepting mouse clicks. Here's the code I'm using:


Code:
this.pictureframe.onRelease = function() {
getURL("http://www.a_web_site.com");
}


If this were a normal movie clip with some content "hard coded" into it, it would work fine. It's gotta have something to do with the fact that it's a movie clip that's empty until it gets a JPEG loaded into it.

Controlling/Transofmring Dynamically Loaded Pics(jpegs) - File Attached
Hey all,

I'm trying to create this polaroid development effect, which has been tweened, problem is I would kie the pics to load dynamically into a placeholder MC. This is fine, but the JPG loads, flashes upa nd then disappears, meaning the effect is rendered useless.

File can be got here:
http://www.thoughtography.net.au/temp/polaroid.fla

Please help :S

cheers.

Controlling/Transofmring Dynamically Loaded Pics(jpegs) - File Attached
Hey all,

I'm trying to create this polaroid development effect, which has been tweened, problem is I would kie the pics to load dynamically into a placeholder MC. This is fine, but the JPG loads, flashes upa nd then disappears, meaning the effect is rendered useless.

File can be got here:
http://www.thoughtography.net.au/temp/polaroid.fla

Please help :S

cheers.

Problem With Loading Jpegs Dynamically Into Dynamically Created MC's
hey all. I got a problem with loading jpegs dynamically into dynamically created MC's. I've been using NEIL WEBB's tutorial on dynamic creation with event handling through the LISTENER component, which you can see here http://www.actionscript.org/tutorial...MX_2004_Part2/

I have slightly altered the script to accomodate the fact that I want to attach a movieclip with text fields and image holders within it, but the code aint too different I don't think.


Code:
stop();
myMCL = new MovieClipLoader(); //define MovieClipLoader
myListener = new Object(); //define listener
myListener.onLoadComplete = function(targetMC){ //set the onComplete function on listener
trace("targetMC = " + targetMC._name);
targetMC.onPress = function() { //define onPress within function

}
}
//****************************
function initClips(){
//trace(_global.gallery_cnt);
for (i=1; i<=_global.gallery_cnt; i++){
//trace("Attaching Clip - " + i);
this.gallery_TN_holder.attachMovie("TN_Holder", "TN_Holder" + i, i); //attach the movie
this.gallery_TN_holder["TN_Holder"+i]._x = (i-1)*90; //spacing
this.gallery_TN_holder["TN_Holder"+i].TN_Text.text = _global.gallery_array.description;
[i] [i]myMCL.loadClip(_global.gallery_array.main_thumbnail ,this.gallery_TN_holder["TN_Holder"+i].TN_Image);
//load images into clip
}
play();
}
//****************************
myMCL.addListener(myListener); //associate listerer with MCL object
initClips();
The first line ("trace") in bold outputs

Quote:




targetMC = TN_Image
targetMC = TN_Image




which you can see is resulting from the second bold line.

Basically I need some direction with this as to how to reference the clip target for the loaded JPEG, as my output in the movie shows the attachMovie works, as does the text change within the individual "TN_Holder" clips. What the hell am i doin wrong, cos my eyes are kinda starting to go kinda funny looking at this stuff!!!!!

Thanks for any help!

Browser Alters Position Of Jpegs; Also: How To Close Swf Within Swf?
Hi. Thanks for looking at this!

I just posted a Flash website on the web. I have two problems.

1) I have thumbs which, when clicked, open up large jpegs. Offline, the jpegs line up perfectly. But on Internet Explorer, the jpegs are half off the screen. This is the actionscript I am using to control placement (officefinal1 is a jpeg):


Code:
on (release) {
openUp = _root.attachMovie("officefinal1", "officefinal1", 2);
openUp._x = Stage.width / 2 - (openUp._width/2);
openUp._y = Stage.height / 2 - (openUp._height/2);
openUp.onRelease = function() {
removeMovieClip(this);
};
}
How can I fix this?

2) This is pretty simple I think. I have a game swf on the site. If you click on the game jpeg, the game opens up and you play it in the browser, no problem. But when you want to get out of the game, the only thing you can do is hit the "back" button on the browser, and that kicks you out of my site completely. What can I do to let me close out the game yet remain in my site?

Thank you very much! I really appreciate your help!

Dynamically Loading Jpegs
Hi Flash experts,

Have two questions, hope you can come to the rescue as I am pretty new to Flash.

1) Is it possible to display an image in Flash? Say I have a text file containing the URL to the images, is it possible for flash to read those URL and display it?

2) Is it possible to change the Flash canvas size (after it has been published) using Actionscript?

Thanks!

- boon

Dynamically Load Jpegs
Is it possible to dynamically load jpegs from a text file? Thanks

Loading JPEGS Dynamically
Hi people!

Does anybody know of a tutorial on Loading JPEGS Dynamically?

Could really do with it!

Cheers

Deadhands

Dynamically Preloading Jpegs
Hi there,

I know this has been asked a thousand times, but my problem doesnt seem to have been answered anywhere.

When i go to perform getbytestotal on my dynamically pulled images, it just returns a value of zero instead of the actual image size.

Does anyone have any ideas why this would be occurring ?
My code looks something like this.

_root.createEmptyMovieClip("imageHolder1", 201);
_root.imageholder1.loadMovie( +fsdir +fsimage1, "_root.imageHolder1");

bT =_level201.imageholder1.getBytesTotal();
bL =_level201.imageholder1.getBytesLoaded();

etc . . .

Any ideas folks ?

Loading Jpegs Dynamically
Hey All,

i was wondering if someone could maybe tell me the answer to this.

ok say your making a menu from XML with a for loop

how would you go about loading the thumbnail image into the holder clip, i know the XML is working coz i traced it but well look.

...

_root.nav.attachMovie("module","module"+i,i)
_root.nav["module"+i]._y = (i*heightTotal);
loadMovie (picXML[i],_root.nav["module"+i].pic);
trace (picXML[i]);

..

third line see this is prob the worst thing i have tried so dont make fun of me

i tried

_root.nav["module"+i].clip.loadMovie (picXML[i]);

(clip being the holder for the jpeg)

that dont work either but i know for a fact the xml is giving me the name

1.gif
2.gif etc etc

Any ideas what im doing wrong? Never used this loding in before of images and its got me

thanks :P

Loading Jpegs Dynamically?
I saw that this is possible and am wondering if it's just like dynamic text? Are these jpegs from an outside source? Any articles or tutorials about this would be amazing. Thanks

Dynamically Load Jpegs?
Is it possible to dynamically load jpeg images into your swf movies?

I'm working on a shopping cart and would like to be able to load images of various products on demand. I'm using Flash 5, and can't find anything that allows this so far. The closest I can get is to create a small swf file with an image statically embedded in it, and then use the loadMovie() actionscript function...

This is obviously not a viable solution for a shopping cart application where an administrator of the store uploads new pictures of various products on a regular basis.

Dynamically Generating JPEGS
Help....

Does anyone know how to dynamically generate JPEGS from Flash?

Got this project where, the user creates a wallpaper by
1) Selecting the a dog species
2) Selecting a series of accessories to dress it up with such as hats, coats, shoes, collars etc
3) Then the user can save and export their creation as a wallpaper.

I am ok with points one and two but the exporting out to JPEG is where I am stuck. Any suggestions would be appreciated?

Dynamically Linking MP3 And Jpegs
Every MP3 and Jpeg on my website is loaded Dynamically via the loadSound method. It works perfect on the final SWF and it also looks good on DreamweaverMX. However when uploaded to the webserver via FTP, the SWF plays fine but nothing that was dynamically linked will show up. I uploaded all the MP3 and Jpeg files to the server also but the problem still persists. Any help? Thanks for your time

Frank P

Dynamically Loading JPEGS
I'm creating a little movie that will play through jpegs. nothing fancy, just a back and next button. My code doesnt work and i cant figure out why.

Any insights?

Thanks

Greg


ActionScript Code:
//create array with jpeg info
var slides:Array = new Array("1.jpg", "2.jpg", "3.jpg", "4.jpg");
 
//create and set properties for images to load into
createEmptyMovieClip("picture_mc",1);
picture_mc._xscale = 20;
picture_mc._yscale = 20;
picture_mc._y = 20;
picture_mc._x = 20;
 
//init variable
var currentSlide:Number;
 
//function to load images
function changeSlide(number){
    if (number >= 0 && number < slides.length){
        currentSlide = number;
        loadMovie (slides[1], "picture_mc");
        }
}
//call function
changeSlide(0);
 
//back and next buttons
back_mc.onRelease = function(){
    changeSlide(currentSlide - 1);
}
next_mc.onRelease = function(){
    changeSlide(currentSlide + 1);
}

Dynamically Loading JPEGs And Then Downloading Them
I'm a newbie and I want to dynamically load a jpeg from a button. Once the jpeg opens, I want to download it. Is this possible? Any coding tips would be great. Hope this makes sense. Thanks for any recommendations!!

Dynamically Loading Jpegs In A Movie
Hi all,
I am trying to create a flash movie that will dynamically load a series of different jpegs. I need the jpegs to load at runtime so that they are not all downloaded at the sametime. Also, is there a way that i can have the images appear for 5 seconds before the next picture loads. I don't want there to be any user control, basically scrolling 10 pictures one after the other for about 5 seconds each.
I've seen it done with user controls but am not sure how it can be created to scroll aoutomatically.
kudos
Steve

Dynamically Load JPEGs And/or GIFs?
can i dynamically load JPEGs and/or GIFs into an empty movie clip?

or can i only do it with PNGs and SWF?

I am using 6 and cannot develop on 7, sadly.

Loading A Series Of Jpegs Dynamically
Ive been asked to make a presentation which can load jpegs dynamically into flash. This is of course relativily easy to do. However, it needs to load a series of Jpegs as part of a slideshow from a folder which will be continously updated with pictures. It also needs to go through the slideshow automatically and not require a user to operate through it.

As a new picture is inserted into the folder it needs to be added to the slideshow dynamically (obviously the pictures will be named like picture001, picture002, picture003 etc etc). Also the tricky part is this needs to be done without me changing the flash script at any time.

IS this possible to do? Is it easy?

Dynamically Loading Thumbnail JPEGS
ok, so I have a crazy wierd problem.... I am basically loading 28 thumbnails into a flash gallery, which seems to work flawlessy inside of flash, now when I try and load it online, it seems to fall over and I cannot work out why.

Its using full paths, so I dont think its a path issue (on the same server too)

I have 28 place holders, all labelled sub1 to sub28 consecutively.

Im using the following code to load the movies, with the totalIMAGES variable set to 28


while (x<_root.totalIMAGES) {
x++;
loadMovie("http://www.puredirt-x.com/photos/"+_root.gallDir+"/thumbs/"+x+".jpg", "sub"+x);
}
stop();

But it seems almost as though its not waiting for all these items to load in time? any ideas as to whats happening here?

Thanks for any help in advance!!

Preloader For Dynamically Loading Jpegs?
Hi,

Im using Flash MX (export to player 6)

had a trawl through the board but couldnt' find anything on this. I want to dynamically load in a jpeg at run time (I know, just use loadmovie), but I want the equiv of onLoad, so I can run a little preloader while the jpeg is loading, any ideas how to do this??

thanks for any help
boombanguk

Dynamically Loading Jpegs For A Set Time
Hi,

A simple problem that I don't seem to be able to work out!

I have 15 images in the library.
I would like to dynamically load each one, one after the other, to the stage for 5 sec each, and when it gets to the fifteenth I'd like it to go back to the first image.

Any ideas?

Preload Jpegs Of A Dynamically Attached Mc
Hi all. Well onjce again I have been scanning the threads and cant find a direct solution to my problem, or at least I dont know how to implement it if I have :s Anyway what I am doing is this.

I am doing the website for a furnitre company that has a large product catalog, around some 200 photos.

In the main swf. I have all the thumbs and when I click on one thumb depending on what category it is, it will load the external swf. and also a variable that says which photo to show (which frame to go to).

for examplle if I click on a thumb of a bed it will load beds.swf with a photo value of 6, which will go to frame 6 in the beds.swf.

Now in beds.swf I am attaching a movie clip with an instance name of beds dynamically into an mc called photo_holder using the attachMovie function.

The beds movie clip has 40 - 50 keyframes with an mc on each frame which then holds the bitmap. So the target to one photo would be _root.photo_holder.beds_attached.bed1

Then I have a gotoAndStop(photo); action where photo is the variable I loded from level0.

Ok the problem is the following.

I can add a preloader onto a scene before everything, however, I only know how to make the preloader load all the photos. I dont want to do this cause if the user wants to view one photo, they have to wait for all 50 high res photos of beds to load, of course, they wont have to wait for the next bed they click on but its still a pain.

I tried doing some tests last night using the getBytesTotal() function but it only seems to return a value if what I am targetting is in the same frame number where I have that action. Otherwise it returns undefined. Since this clip is loaded dynamically, I have no idea how to preload something that hasnt been called on yet. Or in other words, get the Total Bytes of a photo before showing it, or whatever. Its kinda hard to explain, does anybody have any ideas?

I tried _root.photo_holder.beds.bed1.getBytesTotal(); but it always returns undefined.

Thank you very much

Ted

Limitations On Dynamically Importing JPEGs?
Does anyone know if Flash has a limitation on dynamically imported jpegs? I find that maybe 30% (maybe more) of the jpegs I have do not import into Flash (using LoadMovie).

I think I read somewhere that you can't import progressive jpegs dynamically. Is that it? Or is there something else?

Cheers,

Mike

Preload Jpegs Of A Dynamically Attached Mc
Hi all. Well onjce again I have been scanning the threads and cant find a direct solution to my problem, or at least I dont know how to implement it if I have :s Anyway what I am doing is this.

I am doing the website for a furnitre company that has a large product catalog, around some 200 photos.

In the main swf. I have all the thumbs and when I click on one thumb depending on what category it is, it will load the external swf. and also a variable that says which photo to show (which frame to go to).

for examplle if I click on a thumb of a bed it will load beds.swf with a photo value of 6, which will go to frame 6 in the beds.swf.

Now in beds.swf I am attaching a movie clip with an instance name of beds dynamically into an mc called photo_holder using the attachMovie function.

The beds movie clip has 40 - 50 keyframes with an mc on each frame which then holds the bitmap. So the target to one photo would be _root.photo_holder.beds_attached.bed1

Then I have a gotoAndStop(photo); action where photo is the variable I loded from level0.

Ok the problem is the following.

I can add a preloader onto a scene before everything, however, I only know how to make the preloader load all the photos. I dont want to do this cause if the user wants to view one photo, they have to wait for all 50 high res photos of beds to load, of course, they wont have to wait for the next bed they click on but its still a pain.

I tried doing some tests last night using the getBytesTotal() function but it only seems to return a value if what I am targetting is in the same frame number where I have that action. Otherwise it returns undefined. Since this clip is loaded dynamically, I have no idea how to preload something that hasnt been called on yet. Or in other words, get the Total Bytes of a photo before showing it, or whatever. Its kinda hard to explain, does anybody have any ideas?

I tried _root.photo_holder.beds.bed1.getBytesTotal(); but it always returns undefined.

Thank you very much

Ted

Limitations On Dynamically Importing JPEGs?
Does anyone know if Flash has a limitation on dynamically imported jpegs? I find that maybe 30% (maybe more) of the jpegs I have do not import into Flash (using LoadMovie).

I think I read somewhere that you can't import progressive jpegs dynamically. Is that it? Or is there something else?

Cheers,

Mike

Loading Jpegs Dynamically And Resizing
Hi everyone.  I am having a little trouble doing exactly what it is i want to do...  I want to load JPG's dynamically into a movie clip.  I started out using a loader component, but the loader only loaded the jpg half of the time.... so after a little research i used a movie clip and the loadMovie() method.  Works all the time, only problem is i want to scale the size of the picture to fit where it should.  I have upload code so the users can upload pictures to the server easily, so pictures will be of different sizes, so using _xscale and _yscale is out.  I considered using server size code to resize the photos as they are uploaded, but am hoping there is an easier way.  Anyone got any ideas?

Dynamically Loading And Modifying Jpegs
Last edited by femo : 2003-06-15 at 04:55.
























I am trying to load jpegs into my movie at runtine using the: 'loadMovie' command. this works fine, but it doesnt align with the cente point at the top left of the MC and I am unable to resize the jpeg.

Can someone help me with this: how do you resize a jpeg that has been loaded into a MC with loadmovie?

thanks

MX---Can I Dynamically Load Jpegs Into An Array For A Slideshow
Howdy Everyone,

What I am trying to do is make one of those ever so played out MX slideshow. I am making it for a display case in the visitors center of National Park. Now the problem I am facing is that there are many other slideshows out there on the web, but they are not very dynamic, and are all dependent on frame by frame placement of the slides. I would like to be able to name my images all the same thing like IMAGE001-IMAGE020 and let actionscript create the fade between the two. I am sure I am going to need to do setInterval and push dynamic names out of an array, but I am not sure. Anyone who could help me along the way I would greatley appreciate it.

Thanks
Tony

Dynamically Loading Jpegs Into A Scroll Pane. HELP
Alright, i need some help. I'm currently designing a website for my band and i need to know how to dynamically load an external jpg into the scroll pane.

i don't want to use a movieclip with export linkage for actionscripts. because that causes the final product to be larger and causes it to freeze up on my server. But, i can't figure out the code to make it load a picture from the same directory. It just wont seem to work.

can someone please just send me the code. (you can name the instances of your scroll pane and all that however you'd like and when i copy/aste the code i'll just switch it to mine. i just need to see an example of the code working.

thanks alot

Copyright © 2005-08 www.BigResource.com, All rights reserved