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




Picture In Dynamic Text Box



is there some way I can put a picture in a dynamic text box?



FlashKit > Flash Help > Flash MX
Posted on: 11-16-2004, 08:40 PM


View Complete Forum Thread with Replies

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

Picture In Dynamic Text
Hi,
I'm just started to use flash mx 2004 (i've tryed professional but's to difficult for me)
But i have a small problem. I have a dynamic text with a scrollbar next to it. The scrollbar works fine. But i want to put an picture under the text (which also should be scrolled with the text.)

I'm very thankfull to reactions.

Sorry for my bad english.

Thx in forward

Can I Include Picture In Dynamic Text Box?
Ok... i just want to confirm that this CANNOT be done.

Ok i have a dynamic text box which loads in a text file when the movie plays. What i want to know is this. Can i include a picture in the text file and it be loaded into the dynamic text box??? Ok ok... i know it is a TEXT box.. so logically it cannot process the picture... but i just want to give it a shot.. or if anyone knows a way around it..

I have checked HTML option. So in the text file, i have HTML tags like <b>, <h1> etc... and it loads perfectly. Those text that needs to be bold was bold etc... I tried to include <img src=.....> but it don't work.. of cos....duh!!

Ok... so anyone knows how?? I need the pic to be loaded externally. Any work around??

Any help is appreciated... and thanks in advanced...

Insert Picture Into Dynamic Text Box
How can you Insert Picture into Dynamic Text Box? I want to place the picture along side the text, to make a biography page, but how do I insert an image to place into the text box?

Any alternatives? Please let me know.

Thanks

How To Insert A Picture In A Dynamic Text Field ?
hi all,

i have a litle problem... can someone tell me and maybe give and example on how can i insert an image into a dynamic text field... ?

and when the picture is insered...can i give it some properties like ( i want to put some text next to the picture ) and can i position that text to "absolute midle", "top", "botton" tot he picture...

please help...

wbwd

Dynamic Picture, Dynamic Text
I'm writing an application that I'd like to work in the following way:

Across the bottom will appear thumbnails with invisible buttons. When you click on one of the thumbnails (invisible buttons) the image is loaded in a loader. In the full size picture, I'd like to be able to hover over sections of the picture and have text updated. The problem is, I'm not sure how to approach it since I'll have about 6 pictures, and each picture would have several 'hotspots' in which to hover over and update text. Some of the text would be lengthy.

Please advise.

Load In Picture With Html Into Dynamic Text Field
hello,
  When i am loading text into a dynamic text box, i write out my html in a *.txt file and then load it into flash. But my problem is that it is only loading in text and not any pictures. at first i considered it wasn't possible for this to be done, but then i saw it on

http://www.notredem.com/online/step2.html
(load the page, click on "CLICK HERE to enter hardcore version", then you will see some text fields with scrollbars. This is what i am talking about)

so does anyone know how you would load pictures into a dynamic text field using an external *.txt file?

Trying To Put A Picture Dynamically Generated By Php Inside Of A Dynamic Text Box ..
Basically, I have some php code feeding variables into flash. I want to have a picture associated with some of the lines in a mysql table which are coming through the php code. Now I can get the text to be generated by flash/php/mysql but how could i make the pictures appear in the same manner. I want these all to be in a scroll box inside of flash as well... So how would I make flash display a picture based on a variable, and then how would i put that in a dynamic text box and allow it to scroll up and down with the text it is associated with (keeping it all alligned). A simple answer can be given to lead me in the right direction. Thanks in advance .

Dynamic Picture?
Is it possible to enter a picture from a file ie - a serperate web file...
im hoping to be able to do so so i can change this picture without having to edit the flash every time...

i can do it with text - but cant find a way to do it with pics...

any ideas?

Dynamic Picture
I had a similar question with text earlier and now I'm trying to do it with pictures. You people were so nice to help out...hopefully you can do it again!

I'm looking for a script that'll load a picture when you click on a particular button. I'd also like a text caption to come up below the picture. When you click another button, a whole new picture and caption appears and so forth. Finally, I'd like there to be a default picture in the image container when the page first loads.

I think I know how to make dynamic text appear (i.e. the caption) although I'm not sure how to do the picture part and how to put it all together into a nice little script.

Thank you again in advance.

Dynamic Picture Mask
I`m trying to do a photographic portfolio site and what I`m trying to do is have 4 buttons that show a different picture.

However I want a transition (mask) effect. I want a big cross shape to start small and grow to fill the screen, revealing the next picture.

I don't want to dynamically load the pictures or buttons, just need to know how to do the transition.

Anyone know of example of this? or can help me.

cheers
Simon

Printing A Dynamic Picture
Hi all.

Im currently working on some games for children in MX and would like to know how to add a print function to the images they create on the page.

The game is a silly 'change the bits' of the animal, with 3 buttons changing the head, tail, and legs on a templated body to come up with a silly final product.

There are 10 options for each button and so, numerous final pet possibilities.

Id like to add the ability for the site visitor to print out the final product but havent got the faintest clue how.

Id really appreciate any help. Ive attached the actual .fla itself.

Thanks to anyone that can help.
Paul

Dynamic Picture Uploading - Please Help
I am creating a small picture gallery website in flash. The website has three pages - Vacation 1, Vacation 2 and Vacation 3. Each page should have thumbnails of pictures with a little text at the bottom. When you click on the thumbnail, the pictures should open in full size in a popup.

To upload images into the three sections, I am planning to have an Admin section. The Admin should have the capacity to upload Thumbnails, Full Size pictures and its associated text.

I need to know how to do this - would be great if you could send me a sample file or post a link to a tutorial or a sample.

Thanks a lot in advance.

Can I Add A Picture Into A Dynamic Scroll Box?
or is there a different way to do that?

Scale Dynamic Picture
I have a movie that calls up pictures through an xml file from my images directory. The image scales from 175% to 100%. It works just fine but I want it to appear as though it is scaling down from the center, not the top left registration point.

My guess is that I need to find a way to either, 1) have the x & y values change with the scale to give the illusion of scaling from the center, or, 2) learn how to change the reg point of my blank_mc to the center with actionscript 2. In either case, I think the x & y values will have to change.

I tried to do #1 above but I can't seem to get the x & y values to scale at an even pace. One arrives at 0 before the other.

Have any suggestions?

Thanks in advance.

Code Below:







Attach Code

p = 0;
picture._xscale = 175;
picture._yscale = 175;
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;
}
if (picture._xscale > 100) {
picture._xscale -= 5;
}
if (picture._yscale > 100) {
picture._yscale -= 5;
}
}
};
function firstImage () {
if (loaded == filesize) {
picture._alpha = 0;
picture.loadMovie (image[1], 1);//To change to next program change numbers in brackets
desctxt_mc.desc_txt.text = description[1];
desctxt_mc.date_txt.text = date[1];
picture_num ();
}
}
function picture_num () {
current_pos = p + 1;
pos_txt.text = current_pos + " / " + total;
}

Dynamic Picture List
Hi, all of you....

Can someone give me a hand on how to generate a list containing names of JPG's images, these images will be located inside a folder on the main directory where the xmovie.fla will be, and every time the xmovie.fla runs the images will be loaded dinamically into a different container..... hope being understandable



THANKS

Dynamic Picture Loading1
How do you get more than one image to load in a dynamic text box...or for that matter, at all in Flash?

I've searched hi and lo in the forums for the answer.
I've seen this link:
http://www.actionscript.org/tutoria...XML/index.shtml

It seems to only be helpful for one pic, but trying to do many ends up with something ugly.



Could you all please post any examples or answers to how you may have solved this problem. I want to create a thumnail gallery of images that are dynamicly added to the site....Flash is fun and I don't want to abandon it just because I can't get a dynamic image gallery

Dynamic Picture List
Hi, all of you....

Can someone give me a hand on how to generate a list containing names of JPG's images, these images will be located inside a folder on the main directory where the xmovie.fla will be, and every time the xmovie.fla runs the images will be loaded dinamically into a different container..... hope being understandable



THANKS

Dynamic Picture Loading1
How do you get more than one image to load in a dynamic text box...or for that matter, at all in Flash?

I've searched hi and lo in the forums for the answer.
I've seen this link:
http://www.actionscript.org/tutoria...XML/index.shtml

It seems to only be helpful for one pic, but trying to do many ends up with something ugly.



Could you all please post any examples or answers to how you may have solved this problem. I want to create a thumnail gallery of images that are dynamicly added to the site....Flash is fun and I don't want to abandon it just because I can't get a dynamic image gallery

Dynamic Picture Loading?
I have a Flash company directory which connects to a database to retrieve various pieces of information on the selected employee.  I have pictures of each employee on the server that I'd like to display in my application.  Is there any way I can dynamically retrieve a picture like that without first importing each and every picture into my project's library?  Thanks.

--Ryan

Dynamic Picture File
Is it possible to have flash load from a folder full of pictures? If not, how else would I do this? I want it to load whichever pictures are in a specific location and display them.

Dynamic Image/picture Loading
Hey guys,

I need to load a picture/image dynamically and set it as the background for my movie depending on the user-selection.

The picture has to be loaded from a flie on the disk.

That is, I must not have already embedded it into the movie

Can I do this in any way?

Please help!

Dynamic Thumbnail Picture Issues
Here's my scenario:

MovieClip1
MovieClip2
MovieClip3 ThumbNailMovie
...

on rollOver for each MovieClip, I want the thumbNailMovie to load an appropriate thumbnail picture for the corresponding movie clip.

Issues that have arisen using:
ThumbNailMovie.loadMovie("pictureX.jpg");

followed by adjusting the x,y,height,and width properties
of the thumbNail to allign it into the right place are:

1) the full size image appears on the screen and I have to select another clip before it is properly alligned
- I believe loadMovie places the image onto the stage
before applying the properties to it. I want the
properties applied first! (setting _visible isnt
working)



2) if I move my mouse too quickly between the clips, the thumbNail will actually go blank and stop working completely


I'd appreciate some feedback. Thank you in advance.


-Darin

Dynamic Flash Picture Gallery
I am working to build up this flash picture gallery. I want to be able to see manny # pictures in a lots of folders. For this i need to be able to import variables from flash to php and vice-versa. So far I manage to load variables from php into flash with "loadVariables()", but this does not help me. I need to load many variables (some of wich are arrays) and i can do that in textfields.

Thank You,
Catalin Muresan

Dynamic Picture Loading And Resizing...
I've been searching for the last hour, trying some of the codes posted... but for some reason I'm not having too much success.

I have a container 'picture1' and use the code:

code:
picture1.loadMovie("url");


The picture loads fine, but I want it to be a certain length and width. So I used:

code:
picture1._width = 122;
picture1._height = 122;


Which doesn't show anything at all. To my understanding from what I've searched, the picture wont resize anything that practically isn't there.

SO... How do I load the picture, check that it's there, and finally resize it to height and width exactly 122, because I will have different sized images that I want that length and width.

Thanks for your help!

Dynamic Picture Loading Question.
Hi! This is my first time posting here! I've been reading a lot of the Kirupa tutes and they sure help me a lot. Very detail yet very simple.
I post here because I've, in some sorts, hit a wall. I was wondering how to implement a different version of the XML album in the tutorials. I want to make some sort of photoreel. The thing is that I don't know how to approach loading the pictures.

Here's kind of what I'm trying to do.


The big white rectangle is the stage and the small squares are the pictures. I intend to put two buttons on both sides that will scroll the reel. How do I load only the pictures shown on the stage? And of course, when you scroll through the images, how can the images know that they should be loading?

Any ideas? I'd appreciate it if you guys don't post any code. I'd like to figure out the coding myself. The process/idea behind it is what I don't know.

Thanks in advance.

Dynamic XML Picture Gallery Problem
hi guys, i am trying to make this xml gallery that dynamically resizes according to the picture's width & height. the function resizer() is hardcoded with fix values. i have tried to assign it from the array like below but it works wierd, the border just keep increasing in size.


Code:
menuHolder["but"+i].onRelease = function() {

imageLoader.loadClip(this.path,gallery.imageHolder);

gallery.imageBorder.tween("_width",this.width,1,"easeOutExpo");
gallery.imageBorder.tween("_height",this.height,1,"easeOutExpo");

gallery.imageBackground.tween("_width",this.width,1,"easeOutExpo");
gallery.imageBackground.tween("_height",this.height,1,"easeOutExpo");



};

AS:

Code:
#include "lmc_tween.as"


var galleryXML:XML = new XML();
galleryXML.ignoreWhite = true;
galleryXML.onLoad = loadXML;

function loadXML(ok) {
if (ok) {

var path:Array = new Array();
var thumbs:Array = new Array();
var width:Array = new Array();
var height:Array = new Array();
var sec:Array = new Array();
var color:Array = new Array();

xmlNode = this.firstChild;
total = xmlNode.childNodes.length;

for (i=0; i<total; i++) {

path.push(xmlNode.childNodes[i].attributes.path);
thumbs.push(xmlNode.childNodes[i].attributes.thumbs);
width.push(xmlNode.childNodes[i].attributes.width);
height.push(xmlNode.childNodes[i].attributes.height);
sec.push(xmlNode.childNodes[i].attributes.sec);
color.push(xmlNode.childNodes[i].attributes.color);

menuHolder.attachMovie("button","but"+i,i);
menuHolder["but"+i]._x = menuHolder["but"+i]._width*i;
menuHolder["but"+i].path = path[i];
menuHolder["but"+i].width = width[i];
menuHolder["but"+i].height = height[i];
menuHolder["but"+i].sec = sec[i];
menuHolder["but"+i].color = color[i];
menuHolder["but"+i].thumbs = thumbs[i];


menuHolder["but"+i].thumbHolder.loadMovie(thumbs[i]);

menuHolder["but"+i].onRelease = function() {

imageLoader.loadClip(this.path,gallery.imageHolder);

resizer();

};
}
imageLoader.loadClip(path[0],gallery.imageHolder);


} else {

trace("ERROR LOADIN XML");
}
}

galleryXML.load("gallery.xml");

function resizer() {
gallery.imageBorder.tween("_width",520,1,"easeOutExpo");
gallery.imageBorder.tween("_height",520,1,"easeOutExpo");

gallery.imageBackground.tween("_width",500,1,"easeOutExpo");
gallery.imageBackground.tween("_height",500,1,"easeOutExpo");

background.colorTo(0x336699,1);

gallery.imageHolder.brightnessTo(100,0);
gallery.imageHolder.alphaTo(0,0);
}


onEnterFrame = function(){;
gallery.imageHolder._x = Math.floor(-gallery.imageBorder._width/2+10);
gallery.imageHolder._y = Math.floor(-gallery.imageBorder._height/2+10);


gallery.ploader._x = Math.floor(gallery.imageBorder._x);
gallery.ploader._y = Math.floor(gallery.imageBorder.y);

};



var imageLoader:MovieClipLoader = new MovieClipLoader();
var imageLoaderListener:Object = new Object();

imageLoaderListener.onLoadProgress = function() {
gallery.ploader.alphaTo(100,1);
};

imageLoaderListener.onLoadComplete = function() {

gallery.imageHolder.brightnessTo(0,1,"",1);
gallery.imageHolder.alphaTo(100,1,"",1);
gallery.ploader.alphaTo(0,1);

};

imageLoader.addListener(imageLoaderListener);

///////////////////////////////////
Stage.scaleMode = "noScale";
Stage.align = "TL";

sizeListener = new Object();
sizeListener.onResize = function() {

background._width = Stage.width;
background._height = Stage.height;

gradient._width = Stage.width;
gradient._height = Stage.height;

gallery.x = Stage.width/2;
gallery.y = Stage.height/2;

};

Stage.addListener(sizeListener);

background._width = Stage.width;
background._height = Stage.height;
gradient._width = Stage.width;
gradient._height = Stage.height;
gallery.x = Stage.width/2;
gallery.y = Stage.height/2;
XML:

Code:
<?xml version="1.0" encoding="UTF-8"?>

<gallery>

<picture path="images/img1.jpg" thumbs="thumbs/thumb1.jpg" width="500" height ="500" sec="1" color="#336699"></picture>
<picture path="images/img2.jpg" thumbs="thumbs/thumb2.jpg" width="400" height ="350" sec="1" color="#336699"></picture>
<picture path="images/img3.jpg" thumbs="thumbs/thumb3.jpg" width="600" height ="200" sec="1" color="#336699"></picture>
<picture path="images/img4.jpg" thumbs="thumbs/thumb4.jpg" width="600" height ="200" sec="1" color="#336699"></picture>


</gallery>
example of the file: http://www.jiajin88.com/demo/xmlgallery/index.html

Dynamic Picture Gallery Loading
HI.

I am making a picture gallery in flash. I would like to be able to load the pictures into thumbnails dynamically. I don't want to have to specify how many pictures, I just want to be able to load an image folder with image, count the number of pictures in the folder, and create thumbnails for each one.

I have unsuccessfully looked all over for code on how to do this, and found nothing yet. i will keep looking, but if somebody can help me I would appreciate it.

I haven't found a really good tutorial on making a gallery with thumbnails yet either, so if somebody knows of one, that would help too. I also want to be able to load comments in dynamically, but one thing at a time. All that I am really worried about now is figuring out how to dynamically load the thumbnails, then I should be able to figure everything else out.

Thanks all!!

Scrolling Panel With Dynamic Picture
Hi

I'm trying to make a scrolling panel with dynamic picture in it:
I have two problem
The first, i don't know how to refer to all the item together in order to move all of them together.
Actually, the item are moving but i can move only those that i can see on the screen, not those hidden.

the second, how can i refer to the first and the last files of xml files, because i'm trying to put an if statement to block them like lee has done in his scrolling panel tutorial, by this :

Code:

   if(panel._x >= 89) {
      panel._x = 89;
   }
   
   if(panel._x <= -751) {
      panel._x = -751;
   }


but in my case, it depends of the length of my xml

well, here's my code

Code:


var numOfItems:Number;
var home:MovieClip = this;

var xml:XML = new XML();
xml.ignoreWhite = true;

xml.onLoad = function() {
   var nodes = this.firstChild.childNodes;
   numOfItems = nodes.length;
   for(var i=0;i<numOfItems;i++)
   {
   var t = home.attachMovie("item","item"+i,i+1);
   t.onRollOver = panelOver;
   t.icon.inner.loadMovie(nodes[i].attributes.image);
   t.holder.onRelease = released;
   t._x=-20;
   t._y=i*(i+67);
   }
}

function panelOver() {
   this.onEnterFrame = scrollPanel;
   delete this.onRollOver;
}

var b = stroke.getBounds(_root);

function scrollPanel() {
   if(_xmouse<b.xMin || _xmouse>b.xMax || _ymouse<b.yMin || _ymouse>b.yMax) {
      this.onRollOver = panelOver;
      delete this.onEnterFrame;
   }   

   var ydist = _ymouse-75;
   this._y += Math.round(-ydist / 75);
}
   
   xml.load("icons.xml");



thanks for helping

Urgent Help With Dynamic Picture Menu
Hey guys,

I am wondering if you could help?

for my portfolio section I would like to dynamically create buttons (preferably from a txt file) and then be able to make each duplication of button load a swf into a content box. I am sure this question has been asked a dozen times before..but I haven't found the right tutorial for it.

An example of what I'd like to achieve:
Iso In this guy's 'print' section for instance he's got mini buttons on the left and when you click on them they load a certain swf. I am not sure if those buttons are dynamic or they've been created in flash though..

thanks,
ezz

Dynamic Load Picture -> Small Movement
hello everyone,

i am dynamically loading jpg's into my movie. i load them into a movie clip on level 1 and level 1 also contains a button. they are loaded in a straight line on the screen, so the first one is on the very left and each subsequent pic is located to the right. When the user hovers over the button i do some generic hover graphics effect to let the user know that it's an active area (i.e. border around the picture)

now everything is working correctly, however when the user hovers over the button, all the jpgs to the right that i load nudge themselves a little making the graphics very unsettling to look at.

so if i hover over the very first movie clip(MC) on the left, all the pics to the right nudge themselves. if i hover over the second pic from the right....the last pic moves a little bit.

does anyone know the cause of this? each time i load a new jpg i create a new movie clip and insert the pic into the new movie instance so they should be seperate and unrelated to one another..

i don't get it!!

thanks.
patrick.

Simple Preload For Dynamic Loaded Picture
I need a simple preloader for a single picture.

The problem is that I use

mypic.ondata=function(){
[update preloader code]
}

I need the size of the pic and the number of bytes loaded.


I tried mypic.getbytesloaded and mypic.getbytestotal but they don't seem to work since getbytes.. refer to the main static movie .

Also I do not know if I have to place the update for the preloader in a clipevent(enterframe) on main movie or on the ondata.


I just need to pass name of pic to a swf and I need it to load that pic with a simple preloader progress bar similar to the front pages loads found newseum site.

The preloader is easily implemented when the picture is already in the movie. ie. not dinamically loaded but I need it for dynamically loaded pictures whose name is passed to the .swf via parameters.

Thanks

Dynamic Sliding Picture Menu / Gallery
Hello,

I am quite fascinated by the effect used to scroll a variety of pictures left and right with the ability to halt on a particular picture to click and navigate to another area of a site. Could anyone point me to a tutorial on how this is done? An good example of the effect may be seen on this site:

http://www.calatrava.com (click on the "slide show" link)

Would appreciate any pointers. Thanks

Preloader Does Not Work At A Dynamic Picture Slideshow
Dear all,
Below is the code that I composed follow along with an online tutorial. However, its preloader is somehow not working as I expect. For example, it does not listen to onLoadProgress while loading. After the picture is finished download, it does not turn to transparent. Would someone help me to check what is wrong with the code.
Thanks

this.createEmptyMovieClip("container_mc", this.getNextHighestDepth());
this.createEmptyMovieClip("buttons_mc", this.getNextHighestDepth());
this.attachMovie("loader","locaer_mc", this.getNextHighestDepth());
locaer_mc._x = (Stage.width - locaer_mc._width)/2;
locaer_mc._y = (Stage.height - locaer_mc._height)/2;

var myMCL:MovieClipLoader = new MovieClipLoader();
var myListener:Object = new Object();
myMCL.addListener(myListener);

myListener.onLoadProgress = function(target, bytesLoaded, bytesTotal){
loader_mc._alpha = 100;
var pct:Number = Math.round(bytesLoaded/bytesTotal * 100);
loader_mc.bar_mc._xscale = pct;
}

trace(pct);

myListener.onLoadComplete = function(target) {
loader_mc._alpha = 0;
}

buttons_mc.attachMovie("prev","prev_mc", buttons_mc.getNextHighestDepth());
buttons_mc.attachMovie("next","next_mc", buttons_mc.getNextHighestDepth());

buttons_mc.next_mc._x = Stage.width - buttons_mc._width -10;
buttons_mc.next_mc._y = 10;
buttons_mc.prev_mc._x = 10;
buttons_mc.prev_mc._y = 10;

var picArray:Array = new Array();
var numPics:Number = 5;
var currentElement:Number = 0;

for (i = 0; i < numPics ; i ++) {
var location:String = "images/image0" + (i + 1) +".jpg";
picArray.push(location);
}


myMCL.loadClip(picArray[currentElement],container_mc);

buttons_mc.next_mc.onRelease = function(){
if (currentElement < picArray.length - 1){
currentElement++;
}
else{
currentElement = 0;
}
myMCL.loadClip(picArray[currentElement],container_mc);
}

buttons_mc.prev_mc.onRelease = function(){
if (currentElement > 0){
currentElement--;
}
else{
currentElement = picArray.length - 1;
}
myMCL.loadClip(picArray[currentElement],container_mc);
}

Drawing API And XML, And Dynamic Picture Loading Troubles...
Hey guys,

The other thread I had going was getting a little convoluted, so I figured I'd start another one to see if I could get better results.

I've loaded data from an XML file and put it in an array that contains everything. I'm trying to get the drawing API to draw some shapes dynamically on the stage using this information. They drew fine before when I was using hard-coded test values, but now that it's dynamic it doesn't work, and I think that's because the shapes are trying to draw before they get their values to draw with. Is there any kind of like "on(something)" I can use to ensure everything's fully loaded before I begin drawing? (The XML file's already in an "onLoad" function.)

Secondly, I'm trying to adapt the dynamic XML image gallery Kirupa tutorial found HERE to work when a button is pressed, and have the images load into a container created with the drawing API. Does anybody have any tips on how this could be accomplished? For reference, here's the code I'm using to create the boxes to house the images (each box consists of a nested preloader bar, and the actual container for holding the loaded image):


ActionScript Code:
//main box_root.createEmptyMovieClip("pictureBox_mc",   tempClip_mc.getNextHighestDepth() + 5);pictureBox_mc.lineStyle(1, 0x000000);pictureBox_mc.beginFill(0xFFFFFF, 100);pictureBox_mc.moveTo(calcX, calcY); pictureBox_mc.lineTo(calcX, (calcY + picHeight));pictureBox_mc.lineTo((calcX + picWidth), (calcY + picHeight));pictureBox_mc.lineTo((calcX + picWidth), calcY);pictureBox_mc.lineTo(calcX, calcY); pictureBox_mc.endFill();//loader graphic (a library item):pictureBox_mc.attachMovie("imageLoader", "imageLoader_mc", pictureBox_mc.getNextHighestDepth());pictureBox_mc.imageLoader_mc._x = (calcX + (pictureBox_mc._width / 2)) - (pictureBox_mc.imageLoader_mc._width / 2);pictureBox_mc.imageLoader_mc._y = (calcY + (pictureBox_mc._height / 2)) - (pictureBox_mc.imageLoader_mc._height / 2);//the actual picture container:pictureBox_mc.createEmptyMovieClip("pictureHolder_mc", (pictureBox_mc.getNextHighestDepth() + 25));pictureBox_mc.pictureHolder_mc.beginFill(0xFF0000, 100);pictureBox_mc.pictureHolder_mc.moveTo(calcX, calcY); pictureBox_mc.pictureHolder_mc.lineTo(calcX, (calcY + picHeight));pictureBox_mc.pictureHolder_mc.lineTo((calcX + picWidth), (calcY + picHeight));pictureBox_mc.pictureHolder_mc.lineTo((calcX + picWidth), calcY);pictureBox_mc.pictureHolder_mc.lineTo(calcX, calcY);pictureBox_mc.pictureHolder_mc.endFill();


So there's the stuff being drawn dynamically. I've been trying to work in the code from the tutorial but mostly through just substituting the given variables for my own; I think there's probably something bigger I'm missing.

Anybody have any ideas?

Determain Pixel Size Of Dynamic Picture
Hey all, and a big thanks to all those who have helped me so far.

Right i am pulling in a picture dynamicly and need it's centre to be in the centre of a movie that i attach dynamicly.Like such..

d4 = 500;
_root.createEmptyMovieClip("thumb_canvas1", d4);
_root.thumb_canvas1.attachMovie("thumbs","picture1",200);
_root.thumb_canvas1.picture1.createEmptyMovieClip("thumbcanvas1", 300);
thumb_canvas1._x = 125.3;
thumb_canvas1._y = 169.8;
thumb_canvas1.picture1.thumbcanvas1._x = -48;
thumb_canvas1.picture1.thumbcanvas1._y = -36;
trace(infolder+" / "+ folder[0]);
thumb_canvas1.picture1.thumbcanvas1.loadMovie("http://localhost/testing/images/thumbnails/"+infolder+"/"+folder[0]+".jpg");
_root.thumbs_canvas1.onPress = function() {
};


But sinse all my thumbnails is either 96x72 or 72x96 i cant hardcode like i have done above.. The above is right for the 96x72 but not the other one.
So how can i find the pixelwidth and height of a picture that is pulled in? If i have that i can easily finde the centre.

Thanks

[MX04] Please Help, About Adding Background Picture To Dynamic Thumbnail
I found this great tutorial at

http://www.kirupa.com/developer/mx2004/thumbnails.htm and I have attached the source files.

What I am trying to achieve for days is to add a background image to thumbnails. Actually if someone can help me to put the thumbnails inside an MC which is in the library, I can do the rest.

Best Regards

[F8] Picture Gallery With Dynamic Thumbnails - Buttons Not Working?
Hi!
I trying to make a picture gallery with thumbnails which get dinamically loaded. I succeed loading them all, but when I'm trying to attach a simple button on each thumbnail, I just can't get it to work. All thumbnails do not work as a button should. I know this has been done many many times by many of you and other Flashers, but I can't see what's worng with this code.
Please, I need some hints!

There are only 2 frames:
In frame 1 I have (this works fine):
code:
languaje = "newtext.txt";

MisDatos = new LoadVars();
MisDatos.load(languaje);
MisDatos.onLoad = function(success) {
if (success) {
trace("Success!");
i = 1;
TotalImsGal1 = parseInt(MisDatos.imgTotGal1);
gotoAndStop(2);
}else{
gotoAndStop(1);
trace("Error...");
}
};

incx = 5;
stop();



In frame 2 I have:
code:
stop();
trace("TotalImsGal1 es "+TotalImsGal1);

for (i=1; i <= TotalImsGal1; i++){
this.createEmptyMovieClip ("galery" + i, i);
this["galery" + i].loadMovie("FotosExpo1/TFoto" + i + ".jpg");
this["galery" + i]._x = (0 + _root.incx);
this["galery" + i]._y = (15);
this["galery" + i].onRollOver = function(){trace ("Rolling Over!");}
this["galery" + i].onRelease = function(){trace ("Clicked!");}
//this["galery" + i].useHandCursor = true;
_root.incx = _root.incx + 125;
}

/*
for (i=1; i <= TotalImsGal1; i++){
mc = this.createEmptyMovieClip ("galery" + i, i);
mc.loadMovie("FotosExpo1/TFoto" + i + ".jpg");
mc._x = (0 + _root.incx);
mc._y = (15);
mc.onRollOver = function(){ trace ("Rolling Over!"); }
mc.onRelease = function(){ trace ("Clicked!");}
//mc.useHandCursor = true;
_root.incx = _root.incx + 125;
}
*/

/*
for (i=1; i <= TotalImsGal1; i++){
this.createEmptyMovieClip ("galery" + i, i);
this["galery" + i].loadMovie("FotosExpo1/TFoto" + i + ".jpg");
this["galery" + i]._x = (0 + _root.incx);
this["galery" + i]._y = (15);
this["galery" + i].botons ();
_root.incx = _root.incx + 125;
//trace (this["galery" + i]._x);
}

MovieClip.prototype.botons = function () {
this.onRelease = function () {trace ("Clicked!");};
};
*/


As you can see I've tried to make it work with these 3 variations, but none of them work: Thumbs are loaded but they're not buttons, so the onRelease sentences are just ignored.
Any clue will be most helpfull.
Thank you very much!

Regards,
Manare

Resize Dynamic Photos While Maintaining Picture Layout
I hope this makes sense. I need help in dynamically loading photos while automatically resizing them and maintaining either their landcape or vertical layout depending on how the picture was taken. I found a code that works great to dynamically load and automatically resize to my specifications, but what if the layouts are different between pictures (ie - the camera was held vertically or horizontally when the picture was taken)??

This is basically going to help me in designing a website for my dad's coin business. The code I mentioned previously works great to display square pictures of coins, but I need some way to dynamically load other pictures of varying dimensions.

Any help will be greatly appreciated!!

Dynamic Picture Gallery Help Needed [Flash Side Only]
Hi, im fairly new to flash and im trying to make a dynamic picture gallery

the PHP side of things ive done, i just cant figure out how to get the pictures to dynamically load in flash, once i know the basic principle i can do the rest

i can dynamically load text into the movie, but thats because i create a dynamic text box and just load the text in as a variable, although i dont seem to be able to mimic this method for picture

ive tried reading some tutorials on slide shows which dynamically load picture but i when i tried to mimic the techniques used there it didnt seem to work

so for the moment i want to be able to load just one picture into my movie [for now i will load this off the hard disk] how would i go about doing this using action script only - please be very specific with answers as i am new to flash

in case anyone would like to advise further once ive done this i plan to setup an array of X by Y thumbnails, a PHP script will supply the picture names of the thumbnails

any advice on the picture problem would be MUCH appreciated

thankyou in advance for any suggestions made

How To Dynamic Upload A Picture Into Flash From Html File
Hello, I have one html file and a flash file. In html file, it is functioning like choosing a Tshirt to design, then how to load that Tshirt picture chosen by the user to the flash file for further modification. Thanks a lot for everyone who has some idea. Wait for your reply!

Scrolled Thumbnails Picture Gallery Question? Dynamic Menu?
Good Day!

Can any one help me or give me some ideas on how to make the categories in the photo gallery to be dynamic?

Because ibn the sample it has static buttons like gallery1,gallery2,gallery3,gallery4.

I just want to be that the button s will be dynaiv. any one can help me?

thanks in advance

Text Box + Picture
Hi,

I want do have a <B>“text box”</B> with a <B>picture</B> in it!
So I can scroll this text box, and the picture is also scrolled!
How can I accomplish this?


Please help
Thanks
David

Playing Two Dynamic Xml Picture Gallery Backgrounds As Child Clip At Different Times
Hey guys,
I am a web developer but I am a beginner in flash. I have been trying to find a solution to my problem but I haven't had any luck and I am hoping you could point me to the right direction. My problem is I need to load a different background (child) movie clip that would replace the default one when a button is pressed. I have two background movie clips that should be loaded one at a time. I am also going to post a code snippet as I understand people are wary about downloading code from other people.

To summarize, the main file is sample.fla. This loads two background movie clips (bg_1.swf and bg_2.swf) through movieClipLoader.loadClip() method one at a time. It is supposed to swap the bg's depending on which section of the main timeline they are at (through the on release event of the buttons). The default bg is bg_1.swf which is the "nightlife bg". Clicking on "restaurant" loads the second bg (bg_2.swf "restaurant bg") on the same target so that should replace the first/default bg. The problem is it does not. Unloading works but reloading the same target with a different mc only makes it play the current/original background.
I am really starting to get frustrated because it seems like a trivial thing to do. I am just starting to learn flash and I really like to get better at it. I am thinking maybe it is because of the way the background bg is coded that it is not meant to be loaded and reloaded (i did not code the bg's). If anyone could help in any way, it would be very much appreciated. If my technique is wrong and there is an easier way to achieve the bg swaps, please let me know. Thanks in advance! Any help would be greatly appreciated.

Scrolling Picture And Text
Hi,

In HTML it is possible, that I have, for example, a picture on the left side, and on the right side of the picture I have, for example, a description text.
If I now scroll down with the scroll bar, the picture and the text is moving! Simple HTML!!!

OK, can I accomplish this behaviour in flash too??? If yes, how???

Thanks
David

Adding A Picture To The Text
http://s90040481.onlinehome.us/dd.html ok that's what I got but i dont know how to add a picture that's in the text and scrolls with it. not layered on top.

Wrap Text Around A Picture?
A client has asked me to wrap text around a picture on the top right of the homepage. Can this be done. To be honest, I can't remember ever seeing this in flash. I have done a search for tutorials on google etc but found nothing. I am also including a picture so you can see exactly what I mean

Thank you

Random Picture/text Without PHP
I was trying to do a banner with a random picture in the background, then a random quote or text in the foreground. My purpose in this is to have a picture with a different quote a good majority of the time. I've seen posts about doing it over PHP, but i'm trying to avoid that. I've figure out a way to do it but i have to specify how many pictures and quotes.

example
choice = Math.round(Math.random()*6);
switch (choice) {
case 1 :
location2.loadMovie("pic01.jpg");
break;
case 2 :
location2.loadMovie("pic02.jpg");
break;
case 3 :
location2.loadMovie("pic03.jpg");
break;
case 4 :
location2.loadMovie("pic04.jpg");
break;
case 5 :
location2.loadMovie("pic05.jpg");
break;
case 6 :
location2.loadMovie("pic06.jpg");
break;
}

Only problem i see with this is, if someone wants to add a picture later on, they have to edit the FLA.

Is there a way that someone later on, without the FLA file, can edit a text file or such and have more pictures rotated into the mix?

as in a bin that randomly calls pictures, no matter how many pictures are in it?

Also concerning the quotes. I want the same thing, but for the quotes to be called from a text file randomly. So again, someone can edit a text file, put new quotes in there, and it will be randomly called.


My apologies for the long post. Any help would be greatly appreciated. Thanks.

User Uploads Picture > Can Move And Edit Picture With Tools In Flash File
Hello,

I am looking for some help with this. It seems like something that can easily be done.

http://www.sonypictures.com/movies/t...customization/

I am looking for the user to be able to upload their picture, and then the picture loads into the flash file. once in the flash file, they can move their picture up, down, left or right, rotates in a circle, and also click a button that makes their picture smaller or larger.

I am working on a project for my family, so they can put their picture with an actor and I wanted to know if anyone could point me in the right direction for this?

Thanks so much in advance.

Enlarging A Thumbnail Picture On A Separate Window The Same Size Of Picture
Hi,
I feel like a dumb, but I still need to ask this question:
When you are using thumbnail size pictures acting like buttons, how can you create a link to a new window page the size of the new enlarged picture only?...I don't want a new window showing the picture with a white background covering 100% my Flash site..
You see, I told you it was a dumb question...
Any help?

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