Loading Images
i have no idea how to do this i hope someone can help, does anyone know how to make it so while in the .swf you can load pictures into the movie?
FlashKit > Flash Help > Flash ActionScript
Posted on: 10-24-2007, 10:43 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Loading External Images Randomly, Getting The Amount Of Images Out A *.txt
hello there!
i've made an a script that loads images externaly from a specific map
randomly. there's only one thing:
how can flash learn to know how many images are loaded?
it's for a client so he can only upload the images and that's it.
can he somehow fill in a *.txt-file that flash can use further???
this is my sourcecode for the external-stuff:
code:
_root.importImage = "background_netomzet"+random(*)+".jpg";
(the * has to be a value that needs to be generated by how many pics
there are in the image map")
thanks a million people!
g
Loading Images Into A Container-H And V Images Centered
I am trying to load multiple images into a container clip to make an image gallery. Since there are both horizontal and vertical images I want the images to load into the center of the container clip (the center of container clip is aligned with the center of each image) because I cannot align both h and v images in my design by a corner. how do I do this?
Thank you!
Loading External Images Loading Bar (Movie Clip)
I have managed to have external images loaded with the progress bar. However, when I place these items into a movie clip the preloader no longer works. can someone please take a look at the flash file for me.
http://www.bloggot.co.uk/file.zip
Dynamic Image Loading / Images Not Loading?
This is my first try at loading images with action script. I read through the forums, borrowed code, and adapted it.
///////////////////////////works fine
myvars = new LoadVars();
myvars.load("alldoorsdesc.txt");
myvars.onLoad = function (success) {
if (success) {
_root.doorsinsttxt.htmlText = myvars.d1txt+"<BR><BR>To order call us at 505 934 8888";
//I would like to create a for loop here so addidtional
//items can be added, is this possible?
_global.dr1txt = myvars.d1txt;
_global.dr2txt = myvars.d2txt;
_global.dr3txt = myvars.d3txt;
_global.dr4txt = myvars.d4txt;
_global.dr5txt = myvars.d5txt;
}
};
///////////////////////////doesn't trace to loaded door
var doormovie = _root.createEmptyMovieClip("imgmovie",_root);
doormovie._y = 100;
doormovie._x = 300;
doormovie._width = 300;
doormovie._height = 300;
function loadpic(num){
trace("inside loadpic" +num);
doormovie.createEmptyMovieClip("img"+num, num);
doormovie["img"+num].loadMovie("images/door"+num+".png");
//// I'm not sure about this line
doormovie["img"+num].onload = function(){trace("loaded door"+num);};
stop();
}
function unloadpic(num){cont["img"+num].removeMovieClip();}
function unloadAll(){cont.removeMovieClip();}
loadpic(1);// load the inital picture
----------------------------
Are all these functions loaded into the root visible from another movie that is imported with getURL ? Or do I have to copy the functions to that imported movie?
Loading Order - Dynamically Loading Images
Flash 5
I am trying to control the loading order of dynamically loading images. If I have 12 placeholders (4 columns by 3 rows) for the images (e.g. 12 instances of a movie clip) each of which loads a different JPG or SWF. I want the 1st instance/placeholder to completely load the image dynamically before the next instance starts to load the next image and so on. How can I ensure image1 is dynamically loaded before image2 and then image3 etc...
If I put each instance on a separate frame on the timeline will it stop on each frame until the instance is loaded before moving onto the next frame? I have seen the effect im trying to recreate on both:- www.rui-camilo.de and www.andyfoulds.co.uk
Many Thanks in advance.
Loading Images
My website http://www.tbtsun.com has many images and it is 6 megs all together.... I wanted to know if there was a way for the images to load when people want to view them. Please e-mail me at thesmack@optonline.com I need help if someone can actually DO IT for me. They will recieve many thanks and credit on the website.
PLEASE HELP
Loading Images
Hi everyone
Is there any way to load images in real time? I'm trying to made something like a slideshow, but the images will be changing day by day and I thought that maybe there should be an instruction to load an image...
Can anyone help me? I will appriciate a lot.
Loading Images
Hi all
Is it possible to load an image in flash the same way you can load a txt file.without using generator or some form of template please any help is would be wonderfull.
Cheers
Loading Images
I was wondering if it was possible by Action script
to load images from the outside, like loading variables
from text files.
What I have in mind is to just add jpg images into a folder and for the flash to automatically recognize it and display it, rather then to keep updating the flash file everytime I produce a new image.
Loading Outside Images Into Swf?
I've got a load of photographs I've scanned in (jpeg's). Is there a way in which I could create a type of slide projector showing an image at a time but loading them from a specified folder? I have too many images to put them all in my FLA file, can I load images in like you would load .txt in? At the moment I'm thinking along the lines that I have to call the files i.e. 0001.jpg, 0002.jpg, etc.
Thanks for your time.
Loading Images On The Fly..?
Is it possible to create a flash movie that can open vector (if not what file types) files on the fly (from a data base or ?) and then manipulate them (zoom in, out)...
If so, where do I start?
P.S. Macromedia Web World in San Fran was awesome...
thanks,
Pepe
Loading Images
I would like to assign random images to my home page. every time a user goes to my site they will see different images.
how can i do that??????
thankyou
Loading Images
I want to load JPG files, into an SWF in the same way one loads movies. I think MX can do this.
Any ideas? Is there a LoadImage object?
Loading Images Via XML
I'm a real ActionScript newbie, but it seems simple. Anyways, I'm modifing the following script/movie to add images dynamicaly loaded from XML.
News slider with XML input
The problem is, well simply it isn't working
Here is the main action script:
Code:
//Made by Wwward on 18/06/2002 in Brussels, Belgium...
//Feel free to use and change, if you use it, i would like to know
//it's fun to know that people use this
//just mail me at w_w_w_ard@hotmail.com
//This frame only loads 1 time, when the movie is loaded
nVar = 1;
urlXML = new XML();
urlXML.onLoad = displayXML;
message = "Loading XML....";
urlXML.load("specials.xml");
//This function puts the sentences in an array, the array "item"...
function displayXML() {
hoeveel = 0;
hoofdtag = new XML();
elementtag = new XML();
item = new Array();
hoofdtag = this.firstChild.nextSibling;
if (hoofdtag.nodeName.toLowerCase() == "dday") {
message = "";
item = hoofdtag.childNodes;
hoeveel = item.length;
itemneke = "";
itemneke = item[nVar].firstChild.nodeValue;
mijnstring = itemneke;
//the following is the code in question:
pic = hoofdtag.childNodes.attributes.photo;
//load the swf into MC
loadMovie(pic, "modelHolder");
//end questionable code
}
}
Any feedback is greatly appreciated.
Thanks,
SB
Loading Jpg Images
I have a .jpg image that is loding in to a .swf file and thet .swf fiel is loding in to my .fla file butt when it does it throws the .swf files right top corner to the MC's center is where it loads at.
the only way that i found out how to fix it is when the jpg imag loades in to the swf file that i set the _x -512 and the _y -384 ( all images ar at 1024x768) and than when the swf file loads in to the fla it centers it right on top of the MC.
is ther a way to make the _x and _y at Zero when you load the jpg. i don't whant to have problems later down the road.
Thanks
MadWilson
Loading Images Please Help
Hi m8s
Please help me, how can I find if image is loaded? Image loading from URL source to blank movie clip, I need to know how many bytes are loaded and if loading is finished!
Cheers
Loading Images
Hi yall,
Does anyone no how I can load mutiple images into a movieclip. I'm confused because the number of images is going to change every week...and I do not want to manually update the movieclip every week.
Any ideas??
thanks
Loading Images?
Can you load images from a url within flash and if so, HOW?
Loading Images
Hi there,
I have been using the following code, but I am having a few problems in Flash MX :
{
_root.createEmptyMovieClip("mypic",1);
mypic.loadMovie("125662573A1.jpg",_root);
}
It seems to resize the image to fit the screen and when I try and set any size parameters, it just fails to show it - has anyone got any ideas why it isnt working or what I can do to fix it? Is it because of the "_root" part, what should it be to get it in the current frame or layer?
Thanx in advance,
Sparky.
Loading Images...or Do I Need To?
Well basically I am trying to create my flash site to be friendly for a 56k download...is there any way that I can have the movie load the picture files when it needs them much like an HTML page. I want them to be loaded and appear when the user chooses to view them.
OR do I need to do this...will the flash movie stream on its own...I just don't want my preloader to take too long to load that is why I am concerned...
Help Loading Ext Images
I've looked around and tried numerous suggestions. But I still can't get this to work. My button is loading some thing because the screen changes color slightly. Posting fla. Can someone tell me what I'm doing wrong.
How To Loading Images
LoadMovie.fla::::::::::::::::::::::::::::::::::::: ::::::::+
Frame1:
loadVariables("3c.asp","","GET");
if (bb=="3c")
{
mmm=Number(2);
}
loadMovie("images/image"+mmm+".jpg", "square");
3c.asp
<%Response.write "bb=3c"%>
but it doesn't work!!! why???
Images Loading
Ok, listen up. I need some help
I made an intro to a friends site, used a few bmps, made a preloader that works just fine. But the images refuse to preload. And since they take awhile to show, the music, which was planned to end at the exact time, ends too soon.
Does the IfFrameIsLoaded command recognize images as well?
What can be done to make it load everything, if not?
You can see the intro at:
www.fbb.us
You might see what I mean.
Thanks for any help you might offer
The Grey Mage
Loading Images In A Swf
I have a little problem and maybe you can help me (I can't speak english very well)
I have an input text field
1 button
in the text field you put something
when you clic the button, it opens a browser with the url+the text in the field
but the page only contains an image, the name of the image is different from the text in the TextField
for example, you enter FLASH, clic, and if it is found, the image OK.jpg is loadead in a page, if it isn't found the image NO.jpg is loaded
and I want to know if there is a way to load the image in the SWF instead in a page
Thanks
Saludos
Loading Images...
I have been examining the loadimages file, dynamic slide show that comes with MX.
I noticed that all the actionScript is all together on one frame, rather than attached to different elements like the back & next button. If I were to copy all that script and place it on one frame in my Flash movie, how will it know to work?
Or would it be best to take different lines of code from there and paste the actions onto different elements that make up the slide show player I made?
I am pretty dumbfounded and would like to get this to work today. I don't understand how the one that came with MX can work if there are no actions attached to the next and previous buttons???? I am looking for the simplest possible methods.
If you could please explain it to me! Thanks!!! I'm trying to understand.
I'll be posting more questions as I stumble along later!
Christine
Loading Images From .swf
Hello people!
I need help on this:
is it possible to load images into a swf movie dinamically while it is played?
For example if I have a movie that calls a php file for having a file name as result (stored in a variable in Flash), how can I then load that file (which of course is an image!) into the swf?
Maybe other Macromedia or third party software is needed to have Flash doing this?
What I need to do is an application that allows users to upload images and then the possibility of loading them into a flash control panel on the website.
The first part (upload) will be done in PHP, but I'm not sure about the second part (loading the uploaded images into the swf!).
Thanks a lot in advance, this is important to me!
Loading Images
I have picture thumbnails on the left side of the screen and want an enlarged image to appear on the right side of the screen after the thumbnail (button) is clicked. I would appreciate any help in writing the proper ActionScripting for this process.
Loading Images?
Hi guys
I am trying to load im images @ runtime, I have been told that flash can only do this with .jpg files. Thats fine. I have set everthing up for this.
image url is stored in a db and is then loaded into flash when required. The url loads fine and i can run a trace to make sure of this. Here comes the problem
Code:
this.onEnterFrame = function() {
if (_parent.result == "Okay") {// returns result from loading information from the db
loadMovie(imgurl, img_holder);// imgurl holds the address for the image
}
trace(imgurl);// trace to make sure the url is loaded correctly
delete this.onEnterFrame;
};
This image wont load into img_holder(MC)
This is my first atempt @ loading images this way. am i missing anything, Cheers guys
Loading Images
i'm wondering if there is a way to check if an image has loaded yet. i have an animation, and i want to load a jpg, but i don't want it to do anything until the 3 images i have load.
any ideas?
`grom
Loading Images
Hi,
I have about 10 thumbnails. I would like to display the full size image when they are clicked on. The problem is that preloading all of the full size images takes too long. How can I load the full size images as they are accessed?
Thanks,
Tim
Loading Images
I need to load jpegs into a swf whenever user presses a thumbnail.
Since I don't want the loading time for the swf to be to long I will probably use the load jpeg command. How can I get a loading bar for every jpeg, and have them fade in?
Any good tutorials?
Loading Images
Is there anyway I can load an image (.jpg, .png) not included in the movie, by clicking a button?
Loading Images...
Hey, not sure if this is an actionscript question, but I'll try it. I'm in MX, working on a portfolio site, trying to get images to load when their thumbnail is clicked, but not before. I have a lot of images, and don't want them all loading when the page is first visited. Does this make sense and is there a script I can use to make it happen?
thanks much,
ts
Loading Images From A Cd
Hi,
New day, new problem it seems.
I've made a projector file in flash that I plan to include on a CD.
In the file I have created 3 small thumbnail images that when clicked should open up the full size image in a separate browser over the top.
To do this function I used the getURL command linking the buttons to the full size images that I placed in the project folder.
I figured that when I burnt the folder to the disk, the links would still work, however they don't. When the .exe file is opened on another computer the error message states the link isn't accesable as the files are on MY computer.
Is there another way of doing this? Perhaps by including the full size images within the .exe file?
Thanks for all the help so far.
Ad.
Loading Images
hope someone can put me out of my misery,
I'm trying to have a movie clip on the main timeline. in the movie clip i want to pull in 3 different images and fade between them. how do i go about this.
any help would be great.
Ta in advance.
Yam.
Loading Images
good evening people.
this is my problem:
i'm loading images to a flash movie, and if there is no image for the adress i gave, how can i make to load another image with texy "no image" or something?
waiting....
Loading Images
Hi guys,
I'm making an image slideshow in flash mx 2004.
To reduce the loading time and the size of the movie:
is it better to load image with loadmovie actionscript from external swf or use attachmovie from the library?
I don't know if the question is clear, you know, i'm italian
thanx
Noir
____________________________
vangogh
Loading Images.
Hi,
i have a swf file that i am trying to load jpg's into, there ae a lot of images so i want to be able to load the image selected from the nav, rather than make a swf file of all the images. how do i specify the location where the file should load, that is, I want it to load at 100 pixels right and 75 down from the top. is there a way to do this?
also I would like the loaded image to be a button that can link to a pop up.
is creating seperate swf's for each image the way to do this?
thanks.
Pre Loading Images - Help
Hi there !
I have a image gallery for a industrial site im working on at the moment and currently I have a pre loader that pre loads all the pictures and then each one fades in and out and the next one fades in, see attached fla.
What Iike to do is to pre load the first image in, have that stay until the next one is pre loaded, and then that one fade in instead of the viewer having to wait until all pictures are pre loaded..
Hope this makes sense......
Thanks for your help !
Nick
Loading Images
hello
i am a rookie to the world of flash and a novice webdesigner and i am trying to create a site in flash that can load images from an external source.. to make the site easy to update...
as in a person can upload the image files speratly and flash can load them in individually into the movie without having to have a library swf file.. is this possible? (i presently use Flash 5)
i welcome any advice in helping me tackle this problem
thank you
Rafiq
Loading Images
Hi, i've looked all over for information about loading jpg's into flash at runtime...
so i've tried many combinations of the loadMovie method and dont want to have to resort to using XML
why does
Code:
loadMovie("image45.jpg","img1");
simply not want to work
image45.jpg is in the same directory as the .swf when its run...
its drivin me crazy dammit! lol
thanx
Lee
Ps: attached a zip of what i cant get working...
Loading Ext. Images
Hey outthere,
here's a general question. If In my site i am laoding external .jpgs, then removing them, do they get cached? the nxt time round if they are reloaded do they appear faster (or instantaneously)
Q: Images Not Loading On Mac
I have a site where I'm loading some images pulled from a db into a mc and then you can view them all. Everything works great on a PC, however, on the mac I am having issues with images showing up. I am creating a container for the images via attachMovie() and then I load the images into a mc in that container via loadMovie(). Does anybody have any ideas or anything? Thanks!
Q: Images Not Loading On Mac
I am loading images via loadMovie and they work fine and everything on a PC but do not show up on a Mac. Any ideas?
Thanks!
Loading Images
hai friends,
i have the swfs or images loading dynamically. i want to load the swfs
or images some set interval . My question is how to load swfs or images using
set interval and timer control.
thanks
Srini.U
Images Not Loading From XML
Hey everyone.
I have an XML doc with a list of urls which are loaded
into empty movie clips which were created at authoring time.
The code I used is working fine but is way too big,
here is a sample...
xmlData = new XML();
xmlData.ignoreWhite = true;
xmlData.onLoad = loadXML;
xmlData.load("images.xml");
function loadXML(){
xmlNode = this.firstChild;
image = [];
total = xmlNode.childNodes.length;
for (var i = 0; i < total; i++){
image[i] = xmlNode.childNodes[i].childNodes[0].firstChild.nodeValue;
}
loadXMLSmallimages();
}
function loadXMLSmallimages(){
_root.picture0.xmlPicture0.loadMovie(image[0], 1);
_root.picture1.xmlPicture1.loadMovie(image[1], 1);
_root.picture2.xmlPicture2.loadMovie(image[2], 1);
_root.picture3.xmlPicture3.loadMovie(image[3], 1);
_root.picture4.xmlPicture4.loadMovie(image[4], 1);
_root.picture5.xmlPicture5.loadMovie(image[5], 1);
_root.picture6.xmlPicture6.loadMovie(image[6], 1);
_root.picture7.xmlPicture7.loadMovie(image[7], 1);
_root.picture8.xmlPicture8.loadMovie(image[8], 1);
_root.picture9.xmlPicture9.loadMovie(image[9], 1);
_root.picture10.xmlPicture10.loadMovie(image[10], 1);
_root.picture11.xmlPicture11.loadMovie(image[11], 1);
_root.picture12.xmlPicture12.loadMovie(image[12], 1);
_root.picture13.xmlPicture13.loadMovie(image[13], 1);
_root.picture14.xmlPicture14.loadMovie(image[14], 1);
_root.picture15.xmlPicture15.loadMovie(image[15], 1);
_root.picture16.xmlPicture16.loadMovie(image[16], 1);
_root.picture17.xmlPicture17.loadMovie(image[17], 1);
_root.picture18.xmlPicture18.loadMovie(image[18], 1);
_root.picture19.xmlPicture19.loadMovie(image[19], 1);
_root.picture20.xmlPicture20.loadMovie(image[20], 1);
}
As I started to add more and more the list of images to load
as you can imagine grew to a stupid size. So I came up with function
that is simple and clean, but now it doesn't want to load the images.
Here is the new code:
xmlData = new XML();
xmlData.ignoreWhite = true;
xmlData.onLoad = loadXML;
xmlData.load("images.xml");
function loadXML(){
xmlNode = this.firstChild;
image = [];
total = xmlNode.childNodes.length;
for (var i = 0; i < total; i++){
image[i] = xmlNode.childNodes[i].childNodes[0].firstChild.nodeValue;
}
loadXMLSmallimages();
}
function loadXMLSmallimages():Void{
for(var i:Number = 0; i < 35; i++){
_root.picture[i].xmlPicture[i].loadMovie(image[i], 1);
}
}
Am I missing something? Thanks in adavnce
Loading Images?
Hello.
I'm trying to pre-load 50 external jpg's in order from 1-50. What would be the best way to do this. I have tried this so many way but they keep loading randomly.
Thank you,
Elizabeth
Loading Images
I have the following code in my swf but when I publish it in html it doesn't display the images. So how can I get the swf file to display the images that are in this particular folder when it is published to html?
Code:
var imgList:Array = new Array();
imgList[0] = "/images/coral.jpg";
imgList[1] = "/images/horizon.jpg";
imgList[2] = "/images/resort.jpg";
imgList[3] = "/images/sunset.jpg";
function chooseTheString() {
randomPic = random(imgList.length-1);
_root.holder.loadMovie(_root.imgList[randomPic]);
}
chooseTheString();
stop();
Loading Images
I need help putting together a simple XML/Action Script load image code into a flash file.
This the code I have for the file:
<_ filename = "http://www.sitename.com/flv/video/i_gotcha.flv" title = "Lupe Fiasco - I gotcha " would like to insert an image here for the bg of the source file.>
How can I do that?
|