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




Button And Images Problem/ Help Needed., Script Issue.



Allright here's the deal,

Basicaly i created a white square and made it a movieclip and called it view.

Then made a bunch of very small icons "buttons" that each one would open a different picture in that movieclip. (like a gallery, multiple very small thumbnails that open up my images on my server into that movieclip)

so i didn't put any script on my movieclip, just on that one button. And that's what i wrote :

on (release) {
view.loadMovie("http://www.alxcote.com/2006/self.jpg");
}


Then i test it and it doesnt open anything in the movieclip. (i think i should add something to the clip, not sure)

any help would be greatly apreciated,

alx



FlashKit > Flash Help > Flash MX
Posted on: 05-25-2006, 12:08 PM


View Complete Forum Thread with Replies

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

HELP NEEDED, With Mouseover Issue
I desperately need to know how to create the images slide over one another on mouseover and come back to its original x position when mouse out, these images are buttons or hyperlinked. Very similar to the front page menu of http://www.carters.com

I looked every tutorial on the net but couldn't find it. PLEASE PLEASE HELP!!

Keypress Issue Got Complicated...help Needed.
Ok here's the situation.

We have an input text field named "type2" on the stage.

We need a couple things to happen here.

Number 1

If the user types 2 from the keyboard not the number pad and then presses the enter key they go to frame 35.

Number 2

If they type any other key without pressing enter they get sent to frame 30 immediately.

I would put our code in here, but since it's not working it would only serve as a visual reminder of our ineptitude. lol

Expertise Needed For A Simple Issue
Hello,

I am trying to get around a customer's firewall issues. They have a local flash sniffer on their intranet and don't want their employees leaving my companies program/their local intranet to obtain a Flash Player.

It appears, however that even if you disable the context menu in flash with Actionscript, the "about Macromedia Flash Player 7" still remains and links to Macromedia.

Also, if you take out the direct links that flash outputs when publishing its HTML in the <object>/<embed> tag does nothing to stop Flash Player from taking a user to Macromedia if the plug-in does not already exisit.

Is there any solutions/hacks/work-a-rounds involving this issue

Thanks,
callard

[help] Expert's Help Needed For Scrollbar Issue
Hi All,
I have a problem for the experts who like a challenge!:

(using mx2004 - publishing as AS1 and fp6)
I am creating a flash application using 2 'Ultimate Scollbars' from flashloaded.com, 1 horizontal and 1 vertical, kinda like a scrollpane. The app has a 'zoom to point' feature which basically scales the grid and positions it so that the point you clicked on is in the centre of the scroll mask after zoom.

The code works because i have tested without the scrollbars, by moving the x and y coords of the grid, and everything looks sweet. However, when i adjust this code to move the scrollbar positions, the grid ends up in the right place, but jumps about all over the place on it's way there. The scrollbars don't seem to like positioning and scaling at the same time.

A possible solution might be to be able to adjust the grid position by setting x and y values for the grid and having the scrollbars adjust to it, rather than setting the scroll position on the scroll bars and have the grid jump around (not sure if this is possiblee or how to do it). Any one got any ideas?

I have created some demo files for anyone who feels up to the challenge. zoomdemos.zip
zoomdemo1 shows what I am trying to achieve with the scrollbars. This doesn't use the scrollbars, instead it adjust the co-ords of the grid, works fine.
zoomdemo2 shows what happens when I try to do the same thing with the scrollbars.
zoomdemo_1step A simplified attempt with a 1 step transition, still no luck.

I have already asked flashloaded about this problem but they are yet to get back to me with a solution. I would really appreciate any help, even if it's to suggest a different approach that would work.

Thanks in advance

Dave

Pop-up Menu Navigation Issue HELP NEEDED ASAP
I need help ASAP,

I have used a pop-up navigation before from the tutorials here, and I recall it working fine... now however, I cannot get it to work at all! I am using flashMX. This the scenario

I have my main stage with 4 different Scenes (blue, red, yellow, green). I have placed a MC on them called "popupmenu". Inside this menu I have two key frames (each with a 'stop()' action) labelled "up" and "over". I have a single button in the "up" frame with the following script

on (rollOver) {
gotoAndStop("over");
}

That script works fine. At this frame, we have the initial button, plus four more buttons appear. Each with there own script. Here is one of the scripts.

on (release) {
gotoAndStop("yellow",1);
}

However, after running the script, the navigation doesn't work, we still are situated in the same main scene (which is 'blue'). What am I doing wrong???? By all accounts, this should work shouldn't it?

Layer / Movie / Dropdown Issue...- Help Needed
I have a main swf that loads in other swf files"pages" and they have images on them. When I use the drop down on the first page it is ok but on the next page "aboutus.swf" I have an image on the top left and the drop down menu hides behind it. How do I fix this so it always loads on top of anything???

Command used to load pages in is: on (release) {
unloadMovieNum(1);
loadMovieNum("aboutus.swf", 1);
}

Please help.

Thanks

Button Issue In Flash - Program Issue
all of a sudden when i create a button and place it on stage i cant click it to drag it, scale or whatever...instead when i hover over it it behaves as in a compiled swf file (cursor changes into a hand,...).
How can i change that to the way it was? Anyone had this problem before? It is becoming really irritating.

Help Needed In Calling Images
Well hey to all i am sorry that i could not be active here i had to take a exams well you all know how it is.

Well here is my problem i am new in flash and i am trying to build a cd catalouge for my self but first i have to tell you i am a very lazy guy ok so now i thought of a concept i have to call some images ok but i dont want it to be called in the movie i want it to be called from a folder like a loop well i think i am makeing my self clear to this point

ok now the prob is i want to call the images from a folder like images and there suold be a feature like i should be able to add images in the folder and it should come in the the movie and if i delete some images they should delete from the movie so in short the thing is i should be able to update and delete the images with out any hassel

well i sound sad right but pls tell me if this can be done or not

so i hope that i would be getting a good reply kkkk

saintjp

Help Needed Loading Images
Hi all i need help with my site i'm hope you can point me to a tutorial for this.

The site is here

I need small thumbnails in the left news part load a 2nd image to the main box on the right. If you could help me out with this that would be great

Complicated Variable Issue - Flash Jedi Needed
OK, I'm really hoping someone can help me figure out a way to do this.

It might help if you know PHP/MySQL but not necessary!

It's kinda complicated, so please bear with me. I'm hoping some flash jedi can help figure it out.

I'm loading in some variables from an external PHP file.

However, I don't know how many values will be coming in.

How can I reference these values? How can I use a value?

For instance, I'd like to store the values in an array or something of that nature, but to do so I'd like to do something like this:

Assuming that I know the number of values "count"

if (count >0) {

myValues[count] = "incoming variable name";
count = count - 1;

}

So if I know the name of the incoming variable, I'm set, that should do it.

Now I can format the variable so the come out like this:

value1 = whatever
value2 = whatever
etc.

But how do update the name of the variable where it says "incoming variable name"?

If I set up something where you had:
incoming = "value" add count;

then I'd guess that I'd get a series of "incoming" values like this:
value1
value2
etc.

but I'm assuming that then if I did:

myValues[count] = incoming;

instead of saving the value of "value1" I'd save the actual string "value1" instead of the variable's value.

Does this make sense?

How in the world do I reference a value, if I don't know how many are coming in?

In PHP you can get a buffer of values and then just loop through where each value in turn is $key, $value.

Can you do that in flash?

Scrolling Images? Quick Help Needed
In my flash file, i have a box where things are displayed, but i wanna fit a couple of images in, but it's bigger than the box, so i wanna be able to scroll down. I have 2 scroll buttons on the box (up and down).
Now my problem is, i dunno how to make those graphics in a some sort of box, then i can scroll by clicking the 2 buttons on that box. please help!

: : : Help Needed With Loading In External Images
Ok.... the problem im having is this :

Im running my web camera at this address

http://www.spotlife.com/users3/gerr...GBR&language=EN

now... it displays an image every 10 seconds and im wanting to pull that image onto my site each time.

So far what ive done is :

Created a movie clip with the instance name of 'picture' and on the 1st frame of that m/c ive put this line of code

loadMovie("http://www.spotlife.com/users3/gerrymckay007/webcam/pic/image.jpg?"+random(9999), picture, "");

Also on the m/c ive added a timer so that it takes the next images every 10 secs which is :

onClipEvent (enterFrame) {
newTime = getTimer();
if (newTime-oldTime>10000) {
this.loadMovie("http://www.spotlife.com/users3/gerrymckay007/webcam/pic/image.jpg?"+random(9999), "");
oldTime = getTimer();
}
}

I get the 1st image but when i goes to get the second it cant for some reason.

Hope you can help me out

Thanx


Oh and the site im trying to get it all working on is www.popcop.co.uk

Have a look at the .fla is u want

Load Larger Images When Needed
my flash site is kind of large...takes for ever to upload on the web. i'm assuming it is my pictures.
how do i make it load my pix only when needed?
so, i don't want to load the whole cache right away (which it is now)
i want the specific pic to load when somebody clicks a button with a jpg in it ...how do i code that? it should go much faster...or...

thanx

HELP NEEDED With Scrolling Images On Website
Hi there,

We have developed a website and at the very final stage the client has decided they are not happy with the speed that the images scroll. We cannot work out how to change the code to slow down the speed that the images are scrolling. I also want to have the mouse activate the images only when the mouse is over the images (scrolling area) and not over the entire website. This is the code we have on the movieclip.

stop();
xm = 0;
//function to set the xpos of the movieclip
function xpos(bar_length,mul)
{
hpos = -200;
scroll_length =35;
incr = bar_length/scroll_length;
xm = _xmouse;
//the amount the mouse needs to move to scroll.
//so the top one is the x posion where it starts on the left, and the bottom one the right.
if(_xmouse <= -200){xm = -200;}
if(_xmouse >= 300){xm = 300;}
scroll_x = hpos - xm;
scroll_x = scroll_x * mul;
x_pos = scroll_x * incr;
x_pos = x_pos + hpos;
return x_pos;
}

_root.onEnterFrame = function ()
{

// call function xpos
x_pos = xpos(500,.20);
with (bar)
{
_x += (x_pos - _x)*.4;
}

// call function xpos
x_pos = xpos(500,.75);
with (menu)
{
_x += (x_pos - _x)*.4;
}

}


The movieclip we are loading into a level on the main movie. you can see the site at www.mediamache.com/loudfire.

Any help would really be appreciated.

Thanks,

Adam.

Guidance Needed: Horizontal Scrolling Images
Hi,

Well I'm trying to create a menu system with images that scroll horizontally. I tried looking at the various posts both here and at were-here.com, but I finally realized that I needed to understand how the AS really worked. So I spent a little time reading and got this far.

onClipEvent (eventFrame) {
_root.menu._x+= 10;
}

Moves my menu nicely across the screen to the right. Cool. My question now is, how can I control left and right movements with buttons?

I took a look at Moock.org's tutorial but I just wasn't getting it.

Any advice?

Thanks so much.

Loading Images In XML With Flash MX Help Needed Please, VERY URGENT PLEASE
Hi all,
i have my grad. project and i have some problems in it.
how can i upload images from xml file

thank you in advance

Flash Catalogue With TONS Of Images... Help Needed, Please.
Hello everyone,
Firstly, thanks for even reading this thread. I really need help, I want to create a flash catalogue but I have over 700 images to plug in. I would like to know if anyone can tell me or direct me to a tutorial of some sort that shows how to plug in 700 images without doing it manually. I've made Flash Catalogues before but I'm not advanced enough in action scripting to make the images load dynamically. Entering the images manually would take a heck of alot of time. The catalogue will be placed on CD so I won't have access to a database. Unless anyone knows of a way to have a database driven cd-rom. Anyways, thanks alot for your help. I really appreciate it.

Thanks,
Chester

Flipping Images - Help From Flash Guru Needed
I am in the process of creating a Flash widget for a client. I am an accomplished Flash designer, but this particular project has got me stumped!

I have posted a “proof of concept” at www.fruitysolutions.com/stuff/flipping.html so you can see what I am trying to do. Obviously the images used will be different in the final version!

The client absolutely loves the concept, but the current approach that I have taken just isn't practical. I have used Swift3D to produce the animated squares manually, and then pieced them together in Flash. This is fine for 6 squares, but the client wants the image to be divided up into about 100 squares, which translates into a lot of manual work! In addition, the SWF file is going to get very big very quickly due to all the frames needed for each square. Lastly, the client wants the option to change the images used at a later date, which simply isn't an option at the moment without starting from scratch.

I cannot think of an easy way around the above problems other than producing the animation at run time, which is what I am trying to do now. However, I can't think where to start! Ideally, there would be two JPGs which Flash would carve up into squares and animate itself but this is really pushing my abilities.

Any ideas??

Flipping Images - Help From Flash Guru Needed
I am in the process of creating a Flash widget for a client. I am an accomplished Flash designer, but this particular project has got me stumped!

I have posted a “proof of concept” at www.fruitysolutions.com/stuff/flipping.html so you can see what I am trying to do. Obviously the images used will be different in the final version!

The client absolutely loves the concept, but the current approach that I have taken just isn't practical. I have used Swift3D to produce the animated squares manually, and then pieced them together in Flash. This is fine for 6 squares, but the client wants the image to be divided up into about 100 squares, which translates into a lot of manual work! In addition, the SWF file is going to get very big very quickly due to all the frames needed for each square. Lastly, the client wants the option to change the images used at a later date, which simply isn't an option at the moment without starting from scratch.

I cannot think of an easy way around the above problems other than producing the animation at run time, which is what I am trying to do now. However, I can't think where to start! Ideally, there would be two JPGs which Flash would carve up into squares and animate itself but this is really pushing my abilities.

Any ideas??

Flipping Images - Help From Flash Guru Needed
I am in the process of creating a Flash widget for a client. I am an accomplished Flash designer, but this particular project has got me stumped!

I have posted a “proof of concept” at www.fruitysolutions.com/stuff/flipping.html so you can see what I am trying to do. Obviously the images used will be different in the final version!

The client absolutely loves the concept, but the current approach that I have taken just isn't practical. I have used Swift3D to produce the animated squares manually, and then pieced them together in Flash. This is fine for 6 squares, but the client wants the image to be divided up into about 100 squares, which translates into a lot of manual work! In addition, the SWF file is going to get very big very quickly due to all the frames needed for each square. Lastly, the client wants the option to change the images used at a later date, which simply isn't an option at the moment without starting from scratch.

I cannot think of an easy way around the above problems other than producing the animation at run time, which is what I am trying to do now. However, I can't think where to start! Ideally, there would be two JPGs which Flash would carve up into squares and animate itself but this is really pushing my abilities.

Any ideas??

Expert Needed. Placing External Images.
Hello... Heres the problem.... I have a JPEG or GIF in a folder somewhere.
In my flash movie, is it possible for the user to type the name of the JPEG or GIF (which is already known to them) and then this image will be placed in the movie??
(Like with the "attach movie" command??)
(Even though the JPEG or GIF is not part of the Flash Project library??)
(When placed, can it take on properties?...Like ._xscale..._height...etc.??)

Someone told me that this could be done with other support, like PHP.
I am clueless to PHP, but can learn by example. Anyone out there who can show me by example if this can be done?

Many thanks in advance. Bob

Flipping Images - Help From Flash Guru Needed
I am in the process of creating a Flash widget for a client. I am an accomplished Flash designer, but this particular project has got me stumped!

I have posted a “proof of concept” at www.fruitysolutions.com/stuff/flipping.html so you can see what I am trying to do. Obviously the images used will be different in the final version!

The client absolutely loves the concept, but the current approach that I have taken just isn't practical. I have used Swift3D to produce the animated squares manually, and then pieced them together in Flash. This is fine for 6 squares, but the client wants the image to be divided up into about 100 squares, which translates into a lot of manual work! In addition, the SWF file is going to get very big very quickly due to all the frames needed for each square. Lastly, the client wants the option to change the images used at a later date, which simply isn't an option at the moment without starting from scratch.

I cannot think of an easy way around the above problems other than producing the animation at run time, which is what I am trying to do now. However, I can't think where to start! Ideally, there would be two JPGs which Flash would carve up into squares and animate itself but this is really pushing my abilities.

Any ideas??

Dreamweaver Mx Rollover Images - Urgent Help Needed Please
hi
this might sound a bit basic but it is causing me a big problem. i am using deramweaver mx, and i am creating a few pages for someone, but when i upload the pages to the interent, the rollover images dont show up. they act as a link, but cannot be seen. please reply with help.
thank you

Odd Issue With Images With Fades
Hey,

For some reason on some of my fades (namely the titanic painting and the baseball player) when it fades through them it looks like the paiting "jumps" to the side. What's up with this?

http://www.weathersdesign.com/adair/

It is in the same EXACT position throughout the whole fade.

Anyone know about this?

Thanks!

Seth

Smoothing Issue XML Images
Hello...

I have this code in as3 that creates dynamic movieclips and adds images in dynamically via xml. I used code to smooth the bitmap before it is attached the the holder movie clip, but I run into an issue of it seeming to only work for the last image in the loop. It attaches and finds all the images with no problem but it seems to only apply smoothing to the last image in the loop.

Can any one help me out? Below is the code that I am using.

var imageList:XMLList=imageInput.image.ilink.text();
var counter:Number=0;
totalImages = imageList.length();

for each (var imageElement:XML in imageList) {

this["holder" + counter + "_mc"] = new MovieClip();

polaroid_mc.addChild(this["holder" + counter + "_mc"])
this["holder" + counter + "_mc"].x = 29.9
this["holder" + counter + "_mc"].y = 44.5

var myBitmap:Bitmap = new Bitmap();
var bitMov:MovieClip = new MovieClip();
var URLReq:URLRequest=new URLRequest(imageInput.image.ilink.text()[counter]);
var imageLoader:Loader = new Loader();
imageLoader.load(URLReq);

this["holder" + counter + "_mc"].addChild(imageLoader)

imageLoader.contentLoaderInfo.addEventListener(Eve nt.COMPLETE, loadBit);
//this["myMovieClip"+counter].addChild(bitMov);

function loadBit(event:Event):void {
myBitmap=Bitmap(imageLoader.content);
myBitmap.smoothing=true;
}



this["holder" + counter + "_mc"].alpha = 0;
counter=counter+1;
}


Thanks

Issue Looping Images From XML
First, I am new to AS and appologize for my coding.
I have a slideshow that plays, while pulling images from XML. The problem I am having is that I can't seem to get it to loop. It loads up and runs through all the images, but after the last one, I get a list of errors. Starting with RangeError #2066. Please help point me in the right direction.


Code:
var fadeTween:Tween;
var images:Array = new Array();
var time:Array = new Array();
var currentimage = 0;
var i:Number = 0;
var maximage = 0;
var loader:URLLoader = new URLLoader(new URLRequest("http://www..photogallery_fish2.aspx"));
function loadXML ()
{
loader.addEventListener (Event.COMPLETE, onLoadSuccess);
loader.addEventListener (IOErrorEvent.IO_ERROR, onLoadFailure);
}
var myTimer:Timer = new Timer(1000);// 1 second
myTimer.addEventListener (TimerEvent.TIMER, loop);
function loop (event:TimerEvent):void
{
currentimage++;
loadimage ();
}
currentimage = 0;
function onLoadSuccess (event:Event):void
{
var loader:URLLoader = URLLoader(event.target);
var myXML:XML = XML(loader.data);
myXML.ignoreWhitespace;
maximage = myXML..image.length();
var number:int = 0;
for each (var property:XML in myXML..image)
{
images[number] = myXML..image[number].@source;
time[number] = myXML..image[number].@time;
number++;
}
loadimage ();
}
function onLoadFailure (event:Event):void
{
trace ("Error loading file: " + event.type);
}
function loadimage ():void
{
picload.source = images[currentimage];
picload.refreshPane ();

var newdelay = time[currentimage]*100;
myTimer.delay = newdelay;
myTimer.reset ();
myTimer.start ();

}
loadXML ();

MovieClipLoader Issue With Images
Has anyone else found a problem with loading images using the MovieClipLoader class? I have found that it has a problem reading the BytesTotal and it doesn't seem to be a flash based problem but rather a Browser problem. When I ran into the problem Fireworks was showing the Bytes Loaded and Bytes Total the same. WHere Internet Explorer 6 was showing the bytes Total as 0 all the way through. Camino for OSX was working fine. The images all loaded fine in the end but the data was wrong. I thought maybe this was security settings or something but I turned off my firewall and still had a problem. Then I tested it by bringing my images into flash and creating SWF files for each image. This fixed the problem, but of course it will not work for every situation. I am guessing a fix would be to have a preloader that detects the issue and if there is a problem it would just indicate that that the item is loading and not show detailed status, but if there is a fix that would be great. Also, I am wondering if anyone else has had this problem?

Please let me know and if I find a fix I will let you know

Also, it worked fine in the Flash Publish Preview Environment.

[URGENT HELP NEEDED] Scroll Textboxes In A Main Textbox & Print Issue
Hi everyone,

I really need help on this.
I have created a maths quiz for my school and at the last frame of the timeline i will display all the questions, student's input answers as well as the correct answers to each question.
But I am using dynamic text to display student's answer and the rest such as Questions and Correct answer i am putting them in a movie clip.

I know that to make a scroll bar we need the textfield to be dynamic and we will put the message in the textfield using actionscript. Because some of the questions are too long and i cant fit all the questions, student's ans and correct ans in a frame, so i separate them into different frames. But now i am told to put all the questions, student's ans and correct ans in the same frame but using Scrollbars to scroll.

Is it possible for me to put all the student's ans (dynamic txt) in one main dynamic textbox and create a scroll bar to scroll?
I am sorry if i sound confusing... Anyone please help? Is it possible to do this?

Another thing is that i need to print out all the answer from that certain frame. But will i be able to print all the thing out since there is the scrollbar?

Help Needed - Login & P/W - Member Upload Images & Text
I have a website that i'm working on, I need to set up a login and password for a large amount of people. I need the Login & P/W to be directed to a page where members can upload images and text.

CAN ANYONE HELP??? PLEASE!!!!

I am using Flash MX 2004.
Mac G5, with all the fixings...

If you need any more info...let me know.

ScrolllPane Loading Images Issue
I have two scrollPanes on my stage, one is called "thumbs" the other is called "myScrollpane". When I click on a thumb image that image gets loaded into myScrollPane. This parts working ok.

What, I am having trouble with is getting my thumb images to display in my thumbs scrollpane. I have a movieclip called thumb_mc which containes a Loader component. I can get the thumb_mc to load into the thumbs scrollPane, but I can't get my images to display in the thumbs Loader component. What am I doing wrong?

Code:
var myScrollPane:mx.containers.ScrollPane;
myScrollPane.contentPath = 'Holder_mc';
thumbs.contentPath = 'container_mc';
//////////////////////////////////////////////////////////////////
MyPicVars = new LoadVars();
MyPicVars.load("Dadphotos.txt");
MyPicVars.onLoad = function(success) {
if (success) {
var t_mc:MovieClip;
Rc = this["DLc"];
//trace(Rc);
for (i=0; i<=Rc-1; i++) {
t_mc = _root.thumbs.content.attachMovie("thumb_mc", "mc"+i, i, this.getNextHighestDepth());
t_mc._x = 5;
t_mc._y = 5+(i*80);
t_mc.i = i;
t_mc.location = this["pic"+i];
t_mc.t_loader.contentPath("Dadphotos/"+this.location);
thumbs.invalidate();
t_mc.onRelease = function() {
//load image into pictures scroll pane
trace(this.location);
myScrollPane.content.myLoader.contentPath = "Dadphotos/"+this.location;
myScrollPane.invalidate();
};
}
} else {
trace("not loaded");
}
};

Pulling Dynamic Images/JS Issue
Hi All,

I have a problem I was hoping I could get some help with. I am using Zoomify (www.zoomify.com) to zoom in on products. The products are loaded up dynamically based on a sting that is passed after the URL. Example: http://www.grjd.com/zoom/dynamic.htm...mifyMinZoom=25

Problem is I am unable to get rid of IE’s ‘click to activate this control’ annoyance. Typically I use the general JS’s out there to remedy the issue, however the javascript that is currently available doesn’t jive with the javascript in the HTML (see below) that declares the variables that in turn pull in the dynamic images.

Does anyone have a remedy for this? Any help would VERY MUCH be appreciated.

Thanks,

Greg.

HTML Code:

<script language="javascript">
var urlString = document.location.href;
var paramIndex = urlString.indexOf("?")+1;
var paramString = urlString.substring(paramIndex,urlString.length);

document.write("<OBJECT CLASSID='clsid27CDB6E-AE6D-11cf-96B8-444553540000'");
document.write("CODEBASE='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0'");
document.write("WIDTH='503'");
document.write("HEIGHT='385'");
document.write("ID='theMovie'>");
document.write("<PARAM NAME='src' VALUE='zoomifyDynamicViewer.swf'>");
document.write("<PARAM NAME='FlashVars' VALUE='" + paramString + "' >");
document.write("<EMBED SRC='zoomifyDynamicViewer.swf'");
document.write("FlashVars='" + paramString + "'");
document.write("PLUGINSPAGE='http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash'");
document.write("WIDTH='503'");
document.write("HEIGHT='385'");
document.write("NAME='theMovie'>");
document.write("</EMBED>");
document.write("</OBJECT>");
</script>

Dynamicly Moving Images Issue
I am working on a image slider. Pretty simple really its controlled by mouse position on stage. If its on the right the images slide to the right etc. once the image slides of the stage it gets moved to the other side behind the other images. It works with one problem the after a while the images start running into each other as they dont appear to be getting placed correctly or moving at the same speed. Not sure why some movie clips would be moving at different speeds then others when its the same code. The code is pretty simple so I am not sure what is breaking it.

the code is pretty simple I have a container mc called newsB in that are dynamicly created clips that hold the news images as you mouse over either the right side of the stage or left they move in that direction. if the newsMC goes of the stage it is relocated to the other side at the end of all the clips. It works but is bugy in the sense that images eventually start to run into each other.

Code:


function Scroll(Lspeed) {
if (_xmouse>Stage.width/2) {
for (p=0; p<=newsCount; p++) {
_root.newsB['newsMC'+p]._x = _root.newsB['newsMC'+p]._x-Lspeed/10;
if (_root.newsB['newsMC'+p]._x+newsMcWidth<0) {
_root.newsB['newsMC'+p]._x = wraperWidth-1;
}
}
}
if (_xmouse<Stage.width/2) {
for (p=0; p<=newsCount; p++) {
_root.newsB['newsMC'+p]._x = _root.newsB['newsMC'+p]._x+(Lspeed*-1)/10;
if (_root.newsB['newsMC'+p]._x>wraperWidth) {
_root.newsB['newsMC'+p]._x = 1-newsMcWidth;
}
}
}

}
var intervalId:Number;
function executeCallback():Void {
Scroll((_root._xmouse-Stage.width/2)/4);
}
intervalId = setInterval(this, "executeCallback", 20);
hope that makes sense
thanx dave

Rectangle Around Textbox And Images Issue
Hello people,

My question applies only when I work in 16 bit system resolution, so when I apply some text and apply 'Anti-alias for readability' with embedded chars, there is some strange filled rectangle showing around the text box. The same applies when I add any kind of filter to a text or image. You may see the exact problem by clicking on the link below:

http://img262.imageshack.us/img262/5171/ingmarksb2.swf

- Notice the rectangle around the text boxes ('anti-alias for readability' applied, it doesn't matters is it static or dynamic text)
- Notice the rectangle around the middle dark-gray box with glowing effect applied

I will say again, this problem occurs only in 16 bit system resolution, it is not applying in 32 bit. Is it possible that this is a nasty bug, or there is solution?
Please help me because this is getting really frustrating.
I am using Adobe Flash CS4, before that I used Macromedia Flash 8. Nothing changed since then.
Thank you for any possible answer

Ognen

Pulling Dynamic Images/JS Issue
Hi All,

I have a problem I was hoping I could get some help with. I am using Zoomify (www.zoomify.com) to zoom in on products. The products are loaded up dynamically based on a string that is passed after the URL. Example: http://www.grjd.com/zoom/dynamic.htm...mifyMinZoom=25

Problem is I am unable to get rid of IE’s ‘click to activate this control’ annoyance. Typically I use the general JS’s out there to remedy the issue, however the javascript that is currently available doesn’t jive with the javascript in the HTML (see below) that declares the variables that in turn pull in the dynamic images.

Does anyone have a remedy for this? Any help would VERY MUCH be appreciated.

Thanks,

Greg.

HTML Code:

<script language="javascript">
var urlString = document.location.href;
var paramIndex = urlString.indexOf("?")+1;
var paramString = urlString.substring(paramIndex,urlString.length);

document.write("<OBJECT CLASSID='clsid27CDB6E-AE6D-11cf-96B8-444553540000'");
document.write("CODEBASE='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0'");
document.write("WIDTH='503'");
document.write("HEIGHT='385'");
document.write("ID='theMovie'>");
document.write("<PARAM NAME='src' VALUE='zoomifyDynamicViewer.swf'>");
document.write("<PARAM NAME='FlashVars' VALUE='" + paramString + "' >");
document.write("<EMBED SRC='zoomifyDynamicViewer.swf'");
document.write("FlashVars='" + paramString + "'");
document.write("PLUGINSPAGE='http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash'");
document.write("WIDTH='503'");
document.write("HEIGHT='385'");
document.write("NAME='theMovie'>");
document.write("</EMBED>");
document.write("</OBJECT>");
</script>

Issue With Loading External Images
I have no problem getting the image to load and even preloading the image. I wonder if I'm doing it the best way still, however, when I get it to load I dont know how to exit the loop and do something else.

What I'm trying to do is keep it on frame 1 while the image loads. When the image is fully loaded tell it to gotoAndPlay(2); but it's freakin out on me so I know my code is screwy.

on frame 1 I have all of the following:


Code:
stop();
image1.loadMovie("boxcovers/a67837_140h.jpg");
_root.onEnterFrame = function(){
infoTotal1 = image1.getBytesTotal();
infoLoaded1 = image1.getBytesLoaded();
percentagea = Math.floor(infoLoaded1/infoTotal1*100);
trace (percentagea);
bar._width = percentagea/2;
if (percentagea >= 100){
gotoAndPlay(2);
}
}
Now I have a movieclip instance named image1 - that loads the image no problem.
bar is my progress bar and since I'm loading a small image i wanted it to be 100 in half hence the /2 on the end.

If I keep the if statement at the very bottom commented out the image loads perfectly with the progress bar etc. and it stays on frame 1. The problem is when I leave that if statement in there it instantly goes to frame 2 before it ever finishes loading AND it doesnt play on frame 2. it goes there and stops which I dont even have a stop there.

Help is much appreciated

Thanks,
Cub

Preleaod XML Gallery Images - Issue
Hello all, (did a search on this and nothing that 100% addressed my problem was found)

I have created a scrolling XML based image gallery using a mix of differant tutrials around the web. The gallery works great and im happy with it, but when i came to add a preloader to the gallery it did not work.

Pre Loader script
frame 1

Code:
bytes_loaded = Math.round(_root.getBytesLoaded());
bytes_total = Math.round(_root.getBytesTotal());
getPercent = bytes_loaded/bytes_total;
_root.loadBar._width = getPercent*100;
_root.loadText = Math.round(getPercent*100)+"%";
if (bytes_loaded == bytes_total) {
_root.gotoAndStop(3);
}
frame 2

Code:
gotoAndPlay(1);
Min thumbnail code frame 3

Code:
function loadXML(loaded) {
if (loaded) {
xmlNode = this.firstChild;
thumbnails = [];
total = xmlNode.childNodes.length;
for (i=0; i<total; i++) {
thumbnails[i] = xmlNode.childNodes[i].childNodes[2].firstChild.nodeValue;
thumbnails_fn(i);
}
firstImage();
} else {
content = "file not loaded!";
}
}
xmlData = new XML();
xmlData.ignoreWhite = true;
xmlData.onLoad = loadXML;
xmlData.load("images1.xml");
/////////////////////////////////////

function thumbNailScroller()
{
this.createEmptyMovieClip("tscroller", 1000);
scroll_speed = 30;
tscroller.onEnterFrame = function() {
if ((_root._ymouse>=thumb_mc._y) && (_root._ymouse<=thumb_mc._y+thumb_mc._height))
{
if ((_root._xmouse>=(hit_right._x-40)) && (thumb_mc.hitTest(hit_right)))
{
thumb_mc._x -= scroll_speed;
} else if ((_root._xmouse<=40) && (thumb_mc.hitTest(hit_left)))
{
thumb_mc._x += scroll_speed;
}
} else
{
delete tscroller.onEnterFrame;
}
};
}

function thumbnails_fn(k)
{
thumb_mc.createEmptyMovieClip("t"+k, thumb_mc.getNextHighestDepth());
tlistener = new Object();
tlistener.onLoadInit = function(target_mc)
{
target_mc._x = hit_left._x+(eval("thumb_mc.t"+k)._width+5)*k;
target_mc.pictureValue = k;
target_mc.onRelease = function()
{
_global.p = this.pictureValue-1;
getURL("javascript:Image('images1.html?p="+_global.p+"')");
//getURL("image.swf","_blank");
};
target_mc.onRollOver = function()
{
this._alpha = 50;
thumbNailScroller();
};
target_mc.onRollOut = function()
{
this._alpha = 100;
};
};
image_mcl = new MovieClipLoader();
image_mcl.addListener(tlistener);
image_mcl.loadClip(thumbnails[k], "thumb_mc.t"+k);
}

Basically I put the preloader on the first two frames of the movie and the content on the thired, once loaded the preloader takes you to frame three (content frame).
Now I think that preloader is loading the page fine but since the xml gallery is populated dynamically once the xml function is loaded the preloader only preloads a small movieclip before its actiually filled with images.


Here is the file (site) I have been working on, I would appreaciate it if a more experianced user of flash could skim over and tell me where im going wrong. I have tried to add a preloader within the loop that populates the gallery but have had no lucl. any help is appreaciated.

Rectangle Around Textbox And Images Issue
Hello people,

My question applies only when I work in 16 bit system resolution, so when I apply some text and apply 'Anti-alias for readability' with embedded chars, there is some strange filled rectangle showing around the text box. The same applies when I add any kind of filter to a text or image. You may see the exact problem by clicking on the link below:

http://img262.imageshack.us/img262/5171/ingmarksb2.swf

- Notice the rectangle around the text boxes ('anti-alias for readability' applied, it doesn't matters is it static or dynamic text)
- Notice the rectangle around the middle dark-gray box with glowing effect applied

I will say again, this problem occurs only in 16 bit system resolution, it is not applying in 32 bit. Is it possible that this is a nasty bug, or there is solution?
Please help me because this is getting really frustrating.
I am using Adobe Flash CS4, before that I used Macromedia Flash 8. Nothing changed since then.
Thank you for any possible answer

Ognen

Pulling Dynamic Images/JS Issue
Hi All,

I have a problem I was hoping I could get some help with. I am using Zoomify (www.zoomify.com) to zoom in on products. The products are loaded up dynamically based on a sting that is passed after the URL. Example: http://www.grjd.com/zoom/dynamic.html?zoomifyImagePath=back/&zoomifyZoom=25&zoomifyMinZoom=25

Problem is I am unable to get rid of IE’s ‘click to activate this control’ annoyance. Typically I use the general JS’s out there to remedy the issue, however the javascript that is currently available doesn’t jive with the javascript in the HTML (see below) that declares the variables that in turn pull in the dynamic images.

Does anyone have a remedy for this? Any help would VERY MUCH be appreciated.

Thanks,

Greg.

HTML Code:

<script language="javascript">
var urlString = document.location.href;
var paramIndex = urlString.indexOf("?")+1;
var paramString = urlString.substring(paramIndex,urlString.length);

document.write("<OBJECT CLASSID='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000'");
document.write("CODEBASE='

Issue With External Images Loading
I have a little gallery that I made (nothing terribly complicated) and would like the images to fully load before they fade in. So the process would be, first image loads in, click next, preloader bar shows over the current image (still showing), then once fully loaded, replaces the last image with the new one fading it in... hopefully that makes sense...

why does this not work? i'm using a movie clip loader...









Attach Code

p = 0;

var img_mcl = new MovieClipLoader();//create an instance of MovieClipLoader

img_mcl.onLoadStart = function (target) {
trace(image[p] + " started loading at = " + img_mcl.getProgress(target));
};

img_mcl.onLoadProgress = function (target, loaded, filesize) {
trace(image[p] + " still loading... " + loaded);
preloader_mc._visible = true; //shows preloader
preloader_mc.load_mc._xscale = 100 * loaded/filesize; //expands the loader in relation to the loaded total
};

img_mcl.onLoadComplete = function (target, loaded) {
preloader_mc._visible = false; //hides the preloader
trace(image[p] + " done loading.");
trace("total loaded: " + loaded);
image_mc._alpha = 0;
fadeIn(image_mc); //fade in image
};

img_mcl.onLoadInit = function (target) {
//trace(image[p] + " is now initialized");
};

img_mcl.onLoadError = function (target, errorCode) {
//trace("ERROR: " + errorCode);
};

function nextImage() {
if (p < (total-1)) {
p++;
if (loaded == filesize) {
img_mcl.loadClip(image[p], "image_mc");
}
}
};

function firstImage() {
if (loaded == filesize) {
img_mcl.loadClip(image[0], "image_mc");
}
};

function fadeIn(_mc) {
_mc._alpha = 0;
_mc.onEnterFrame = function() {
if (_mc._alpha < 100) {
_mc._alpha += 10; //fades in image
}
};
};

Loading Images And Resolution Issue
Hello All.
I seem to be having a silly issue in loading jpegs through an xml file. When images show up the resolution is completley shot! can someone please explain..whats going on.. Much appreciated. Kind of urgent so a response would be appreciated.

Issue With Linked Images (HTML)
Hi guys!

Long time lurker - first post .

I'm having some problems with loading linked images into Flash. The code is in HTML and stored in an external file on my server. This is an issue I just haven't found any solutions to, and I'm hoping someone here has some good pointers.

Let me start by providing you with the simple HTML code that's causing me the headaches:


Code:
<a href="http://www.link.com/link.html" target="_blank"><img src="getAdobeReader.gif"></a>
Now, at first everything looks just fine; the image is loaded and placing the mouse over the image correctly indicates that this is a link by changing the "pointy hand" icon. However, when trying to press the button nothing happens. When moving the mouse outside of the button it still looks like a hand. Now, when pressing the linked button a second time a new IE window opens and the correct URL loads correctly. The strange thing is, that the mouse needs to change position over the button before pressing the second time, otherwise it doesn't work (!). When replacing the image with a simple textlink instead it works perfectly.

Anyone ever seen this before? You can see this issue on the website I'm working on at this moment (work in progress mind you! ).

http://www.sjostaden2.se

Press the second button on the top menu (Föreningar), and then "Stadgar" on the left menu. You'll see the "get Adobe Reader" button on the right.

Thank you in advance!

Regards,
Patrick J.

Dynamically Loading Images Issue//
I'm doing a site where I have a main movie and sub movies that I load using the loadMovie command. In one of the sub movies I want to dynamically load images into a blank movie clip. I can get the images to load if the sub movie is viewed on it's own but, when the sub movie is loaded into the Main movie the images won't load. I guess I'm not sure what to replace the "_root" with. Here's the code (pic_holder is the blank clip):

on (release) {
_root.pic_holder.loadMovie("test1.jpg");
}

Since "_root" always references the Main move I tried the following variations with no success:

on (release) {
_parent.pic_holder.loadMovie("test1.jpg");
}

and

on (release) {
this.pic_holder.loadMovie("test1.jpg");
}


thanks

Loading Images And Resolution Issue
Hello All.
I seem to be having a silly issue in loading jpegs through an xml file. When images show up the resolution is completley shot! can someone please explain..whats going on.. Much appreciated. Kind of urgent so a response would be appreciated.

Images Within TextField (inline Issue)
Hi all,

Using a stylesheet and textfield, I know I can take some XML and create some styles text with rollovers and different fonts styles / sizes.
I've been trying to get this to work and have 2 issues, the first being quite minor.

The first issue is that if I wrap the XML data in CDATA, it's blank, although if I trace everything, it's there.
Taht's a minor issue at the moment though:

My major issue comes with this:
If I want to have some icons like smileys in a string of text, how do I get the images to follow inline?
I have everything set up correctly (as correctly as I think it should be and have read), but the text always breaks if there's an image.
If I change the CSS to inline, rather than block there's still no difference.

A solution I've thought of could be to scrap the stylesheet method and just leave the space where the icon would go blank.
Then use textwidth / character index and attach the icon graphic at the point found, but that would be quite a mission to calculate.

Anyway, here's the stuff I've got at the moment (attached all in zip file, but class codes below as well for a quick check )

Anybody have some suggestions?
Is this impossible?

Main class (document class)
Code:

package Smiley {
   
   import flash.text.TextField;
   import flash.display.MovieClip;
   
   public class Main extends MovieClip {
      
      private var __txt : TextField;
      
      public function Main() {
         
         __txt = this["txt"];
         __txt.background = true;
         __txt.multiline = true;
         
         new Style( __txt );
         new XMLData();
      }
   }
}


Style class
Code:

package Smiley {
   
   import flash.text.TextField;   
   import flash.events.Event;
   import flash.events.HTTPStatusEvent;
   import flash.events.IOErrorEvent;
   import flash.events.SecurityErrorEvent;
   import flash.net.URLLoader;
   import flash.net.URLRequest;
   import flash.text.StyleSheet;
   
   public class Style {
      
      private var __ss : StyleSheet;
      private var __txt : TextField;
      private static var __loader : URLLoader;
      
      public function Style( t : TextField ) {
         
         __txt = t;
         __ss = new StyleSheet();
         
         // set listeners to handle CSS loading
         __loader = new URLLoader();
         __loader.addEventListener( Event.COMPLETE, onLoaded);
         __loader.addEventListener( IOErrorEvent.IO_ERROR, handleIOError );
         __loader.addEventListener( HTTPStatusEvent.HTTP_STATUS, handleHttpStatus );
         __loader.addEventListener( SecurityErrorEvent.SECURITY_ERROR, handleSecurityError );
      }
      
      
      public static function loadStyles() : void {
         __loader.load( new URLRequest("example.css") );
      }
      
      
      private function onLoaded( e : Event ) : void {
         trace("CSS: onLoaded");
         __ss.parseCSS(__loader.data);
         parseStyle();
      }
      private function handleHttpStatus( e : HTTPStatusEvent ) : void {
         trace("CSS: HTTPStatusEvent");
      }
      private function handleIOError( e : IOErrorEvent ) : void {
         trace("CSS: IOErrorEvent");
      }
      private function handleSecurityError( e : SecurityErrorEvent ) : void {
         trace("CSS: SecurityErrorEvent");
      }
      
      private function parseStyle() : void {
         __txt.styleSheet = __ss;
         __txt.htmlText = XMLData.xml;
      }
   }
}


XMLData class
Code:

package Smiley {
   
   import flash.events.*;
   import flash.net.URLLoader;
   import flash.net.URLRequest;
   
   public class XMLData {
      
      public static var xml : XML;
      
      private var __loader : URLLoader;
      
      public function XMLData() {
         
         // set listeners to handle xml loading
         __loader = new URLLoader();
         __loader.addEventListener( Event.COMPLETE, onLoaded);
         __loader.addEventListener( IOErrorEvent.IO_ERROR, handleIOError );
         __loader.addEventListener( HTTPStatusEvent.HTTP_STATUS, handleHttpStatus );
         __loader.addEventListener( SecurityErrorEvent.SECURITY_ERROR, handleSecurityError );
         
         // initialise by loading the xml
         __loader.load( new URLRequest("example.xml") );
      }
      
      private function onLoaded( e : Event ) : void {
         trace("XML: onLoaded");
         xml = new XML(e.target.data);
         Style.loadStyles();
      }
      private function handleHttpStatus( e : HTTPStatusEvent ) : void {
         trace("XML: HTTPStatusEvent");
      }
      private function handleIOError( e : IOErrorEvent ) : void {
         trace("XML: IOErrorEvent");
      }
      private function handleSecurityError( e : SecurityErrorEvent ) : void {
         trace("XML: SecurityErrorEvent");
      }
   }
}


Example.css
Code:

myText {
   font-weight:normal;
   color:#000000;
   display:block;
}


Example.xml
Code:

<?xml version="1.0"?>
   <myStyleText>
      <myText>This is some text, <img src="smiley.gif" width="19" height="19" vspace="-5" hspace="0" border="0" /> which should not break.</myText>
      <myText><![CDATA[This is some text, <img src="smiley.gif" width="19" height="19" vspace="-5" hspace="0" border="0" /> which should not break.]]></myText>
   </myStyleText>

Help Needed: Applying Images/links To Multiple Faces On A 3D Cube
I posted a fortnight ago, but it didn't seem to gain any attention, so I was hoping someone who missed it last time may be able to help me.

I've used two differing 3D Cube ActionScripts, each generates a different type of 3D Cube - one has colored faces and individual links for each side and the other has individual images/movie-clips per face but only one link for the whole cube.

What I want to achieve is a cube with 6 different imaged faces and 6 independent links, can anyone suggest how I could achieve this.

Thanks again

Make Xml Infinite Scroller Load/unload Images In And Out As Needed
I have a xml infinite scroller that currently loads all images all at the same time. It works great but I will need to load about 20 to 30 images that will scroll by and that will cause processing problems.

I am wondering if it would be possible to make the xml infinite scroller only load the images that are in view and then unload them in and out as the scoll by? I have no idea if this is possible but I think many flashers could make use of it.

[F8] Preloading Issue- Images In Html Page
Im redesigning a site atm, and Im looking for a way to load images with flash instead of the old "one at a time"-oldfashioned way. I have 24 100x100 images to load so it wont look that nice if they don't load all together.

This is the site:
http://www.olssongerthel.se/nytt/index.html

Im also going to add a dhtml script that adds an OnMouse function which I don't know how to do in flash.. so Im looking for a way to make a flash preloader for the site, but the site itself shouldn't be flash.

I want a flash loader on top of the images (floating if possible) that loads all the images on the page, but the page itself shouldn't contain any flash after the loading is complete, because I'd like to use the dhtml script...


Is it possible? Anyone got any viable solutions?

No One Would Answer This On The Other Forum [F8] Scrolling Images Issue
I have six images that continuously scroll on mouseover, with only three visible at a time. On mouseout, not only do they need to ease while they stop scrolling, but they need to land back on the first three images.

Can anyone help with this code? I've been all over the web and flash forums and seen very similar issues, but so far haven't seen any code regarding the repositioning exactly where it started. This is my first post, I'm not very experienced with advanced actionscript... thanks!

Loading Images In Dynamically Created MC Issue
Hello !

i've been confronting myself to this issue for 5 hours now, i'm in need of help from the outside world

i'm trying to load a series of external jpg images.
What to be loaded is stored in an external xml file, which indicates the folder along with the file name pattern and the number of images. This is handy since images are numbered incrementally (image_1.jpg, image_2.jpg...)
Finally, i need to position these images as a strip, that is, one next to each other horizontally.

I get the info out of the xml file without issue, the url are correct (if i paste them in the browser, i see the image file) yet, it seems there is an issue with my loading mc code. Can you check and tell me what i'm doing wrong please?


ActionScript Code:
function doStrip(obj:XML)
{
    var project = obj.firstChild;
    var sequences = project.childNodes;
    var project_width:Number = 0;
    var pointerXpos:Number = 0;
    var totalImageCounter:Number = 0;
    var stripContainer:MovieClip = this.createEmptyMovieClip("stripContainer", this.getNextHighestDepth());
    stripContainer._x = 0;
    stripContainer._y = 0;
    stripContainer._height = 200;
    for (var i = 0; i<sequences.length; i++)
    {
        var folder:String = sequences[i].attributes['folder'];
        var numOfImages:Number = Number(sequences[i].attributes['numOfImages']);
        var type:String = sequences[i].attributes['type'];
        var namePattern:String = sequences[i].attributes['namePattern'];
        var imgWidth:Number = Number(sequences[i].attributes['imgWidth']);
        var sequenceWidth:Number = Number(numOfImages*imgWidth);
        project_width += sequenceWidth;
        for (var j = 1; j<=numOfImages; j++)
        {
            totalImageCounter++;
            var filename:String = namePattern.replace('#', j);
            var fileToLoad:String = absoluteUrl+'/'+project_folder+'/'+folder+'/'+filename;
            pointerXpos = Number(pointerXpos+imgWidth);
            instance = 'image'+totalImageCounter;
            var myimg:MovieClip = stripContainer.createEmptyMovieClip(instance, stripContainer.getNextHighestDepth());
            myimg.loadMovie(fileToLoad);
            myimg._x = pointerXpos;

        }
    }
}

Thanks a lot in advance, i look forward to reading your advises!

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