Attachmovie, Why Wont It Work?
I am getting very frusterated with attachMovie() i have the following code on the main timeline:
Code: this.attachMovie('pic_box', 'pic_box', 0, {_x:10, _y:10}) this.pic_box.attachMovie('load_bar', 'load_bar', 1, {_x:100, _y:100}) everything is in the library correctly. now the 'pic_box' gets attached but the other one doesn't. if i do this: _root.attachMovie('load_bar', 'load_bar', 1, {_x:100, _y:100}) it attaches fine. I have a class attached to the pic_box, and if i remove the class ID in the linkage panel, it attaches the load bar. It has nothing to do with what is contained in the class because if i comment out all the code but the: class name {} it still doesn't work. I am REALLY stumped...
KirupaForum > Flash > ActionScript 1.0/2.0
Posted on: 08-18-2004, 04:36 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
How Does Attachmovie Work?
this is what I understand...
MovieClip.(idName,NewName,depth)
for example:
(object the Library movie clip is being loaded to).(idName,NewName,depth)
I do not know what the rest of it really means, like the difference between idName and NewName, or where to enter some of these values, other than "linkage properties". Help?
AttachMovie From Loaded .swf Does Not Work
According to one tutorial I made a movie which load pictures as a separate clips from another movie library.swf. The script si simple:
placeHolder.loadMovie("library.swf");
if (Number(_framesloaded)>=Number(_totalframes)) {
gotoAndPlay (3);
}
loads the library movie and waits until its loaded.
Then there si something like this:
placeHolder.attachMovie("obr1", "myobr1", 1);
placeHolder.myobr1._x = -121;
placeHolder.myobr1._y = -70;
To attach clips to specific position.
The problem is, that it works perfectly on my local machine (and it does not matter, whether I acces the movie directly or via internet server), but when I place it to remote web server, to external clips simply do not appear.
Does anybody have an idea, where the problem might be?
Thanks for any help!
AttachMovie - Why This Script Does Not Work?
How do I get this script to run:
for (i=0; i<10; i++) {
_root.attachMovie("testfilm", "testfilm"+i, "i");
_root.testfilm+i._x=10*i;
_root.testfilm+i._y=10*i;
}
What do I want to do:
In the first frame of the _root-Movieclip shall be loaded 10 movieclipinstances with a different position each.
AttachMovie Doesn't Work
i want to create a movieclip dynamically by using attachMovie but it doesn't create it.
i've attached my fla - file.
thx for your help
Why Attachmovie Won't Work With Root MC
Ok, it's like this - I was working a case on downtown lower east uptown northwest by the shoreline at the docks upstate, when in walks this dame; well, I say dame but I don't just mean any dame etc. etc.
What I mean is: how can I use attachmovie so that it's recognised by my preloader logic?
I've set the linkage so MC in library doesn't Export On First Frame so that preloader should preload.
I've also created an MC on the root with the attachmovie AS.
Does this work?
No - it does not.
It simply will not attach my library MC to the onstage MC.
Doh.
Can anybody advise me please as I would love to crack this.
Regards
Yan
Buttons Won't Work When Using AttachMovie
I'm adding a bunch of buttons to a movie using attachMovie, but they won't work no matter what.
Here's the code:
Code:
_root.gallery_mc.q.attachMovie("hit", "thumbButton" + i, _root.gallery_mc.q.getNextHighestDepth());
_root.gallery_mc.q["thumbButton" + i].onRelease = function() {
trace("It works.");
}
Note: The variable, "i", is defined. It is in a for loop which I have not included in my code.
I can see the buttons on stage, but nothing happens when I click them.
Any ideas on why nothing happens when I click the buttons?
Thanks,
Brendan Benson
Why Doesn't AttachMovie Work?
ok here is my code:
ActionScript Code:
var holder:MovieClip = mc_room.foreground_mc;
holder.attachMovie("testclip", "avatar_" + smartfox.myUserId,
holder.getNextHighestDepth());
trace (holder) //outputs: _level0.mc_room.foreground_mc
trace ("avatar_" + smartfox.myUserId); //outputs: avatar_14
myAvatar = holder["avatar_" + smartfox.myUserId];
trace (holder._x + ", " + holder._y); //outputs: 381.5, 347.5
trace (myAvatar); //outputs: undefined
There is a clip called test clip in the library and if I attach it to the stage, it works. Why doesn't it attach to the holder clip?
mc_room loads an external swf file using a movieclip loader, and when it's completed, this function is called. That shouldn't matter, should it? I'm sure the movieclip is present and I can modify it. It just doesn't let me attach the movie!
I'm really mad at this stupid thing.
Attachmovie Does Not Work On Any Other Level Than It's Own?
Hi
I have a multi-layered movie. I am loading a movieclip into one layer - it contains a variety of items in it's library all linked up and ready to be used via attachMovie command.
I can make the items appear in the movie by using attachMovie on the layer the movieclip has been loaded into. I understand I can't expect to use attachMovie to make the items appear on any other level as this just won't work.
But, is it possible to use attachMovie to make the items appear within a nested layer on the layer it has been loaded onto? Like within a movieclip within the layer it has been loaded to?
I have tried this and it hasn't worked, but maybe someone can help point out something extra i need to do.
Thanks for your help.
Why It Desn't Work (attachMovie)
I use attachMovie to attach another MC 'day'. But it didn't work. Where is the wrong?
ActionScript Code:
spacing = 2;
var i = -1;
while (++i<arDay.length) {
name = "day"+i;
x = i*spacing;
//graph is empty MC on stage
this.attachMovie("day", name, i);
this[name]._x = x;
//Populate the Title dynamic text box
graph[name].title.text = arDay[i];
//trace("dataArray["+i+"]=" +graph[name].title.text);
}
LoadClip And AttachMovie Don't Work Together?
Hi,
I have an empty movie clip on stage ("mc1") that I use loadClip to get a PNG in there.
Then I'd like to attach another MC to that same mc1 ("txt1").
But it won't work.
Everything else works, and I can attach the txt1 clip to other MCs on the stage, but not mc1.
var curClip = mc1.attachMovie("txt1", "tempName", mc1.getNextHighestDepth());
A trace of curClip yields "undefined" as does trace(typeof(curClip));
Am I trying to break some laws of Flash Physics here?
(Note: trace(mc1.getNextHighestDepth()); yields 0... why's that?)
Thanks!
Why Does AttachMovie Not Work After A LoadClip?
Hi, i am trying to attach a movieclip from my library to the movieclip that is loaded.
It does not seem to work. I only can attach it to the _root!
In this example i have an movieclip with an idintifier link of 'round'.
As you can see i can approach the loaded movieclip, because i resized it. I can change it rotation, alpha etc.
But i can't attach a movieclip to it? It does not make any sense.. Is there a fix for it?
Attach Code
var loader:MovieClipLoader = new MovieClipLoader();
var listener:Object = new Object();
loader.addListener(listener);
listener.onLoadInit = function() {
loadinme_mc._width = 200;
loadinme_mc._height =200;
//loadinme_mc.attachMovie("round", "round_mc", this.getNextHighestDepth()); //does not work
//_root.loadinme_mc.attachMovie("round", "round_mc", this.getNextHighestDepth()); //does not work
// this.loadinme_mc.attachMovie("round", "round_mc", this.getNextHighestDepth()); // does not work
_root.attachMovie("round", "round_mc", this.getNextHighestDepth()); // only to the root??
}
loader.loadClip("pic1.jpg", loadinme_mc);
Attachmovie, Why Wont It Work?
I am getting very frusterated with attachMovie()
i have the following code on the main timeline:
Code:
this.attachMovie('pic_box', 'pic_box', 0, {_x:10, _y:10})
this.pic_box.attachMovie('load_bar', 'load_bar', 1, {_x:100, _y:100})
everything is in the library correctly.
now the 'pic_box' gets attached but the other one doesn't. if i do this:
_root.attachMovie('load_bar', 'load_bar', 1, {_x:100, _y:100})
it attaches fine.
I have a class attached to the pic_box, and if i remove the class ID in the linkage panel, it attaches the load bar. It has nothing to do with what is contained in the class because if i comment out all the code but the:
class name {}
it still doesn't work.
I am REALLY stumped...
Cannot Make AttachMovie Work
Hello Flash experts!
Can anyone help me with attachMovie?
(I'm using FlashMX)
I'm probably just being thick but I can't find an explanation of how to use this actionscript.
I have a movie clip in my library called "stage1"
I have a movie clip on the stage called"Intro"
I also have an empty movie clip on the stage called "holder"
When "Intro" stops playing I want "stage1" to be automatically loaded onto the stage.
I have tried putting this script in the last frame of "Intro"
_root.holder.attachMovie("stage1","movie1", 100);
But it does not work.
Should I have some sot of event trigger around this script e.g.
on (enterframe) {
_root.holder.attachMovie("stage1","movie1", 100);
}
Please help if you can, this is driving me mad!
Many thanks
Chazzer.
How Does AttachMovie() Work On Low Bandwidth?
I'm creating a slide show that a low-income user base will be viewing. So, I'm assuming they are mostly on dial-up connections. To streamline the production, I want to use the attachMovie() function and pull the images straight from the library (so I don't have to build out every photo and tween).
What I'm wondering is this: how will this run on a dialup connection? Since the photos aren't actually placed on the timeline and are pulled only when called, how can you do a preload or proper loading bar?
Is it possible to simple dump all the photos off stage on frame one -- will that work as a preloader, or will each still load individually when called with attachMovie?
Any advice or best practice info will be very helpful.
Thanks.
Attachmovie In A Loop ... Doesn't Work
Hi everyone ,
i'm working on a memory game (matching pairs) . Item's masks (12) will be put on the stage with a attachMovie() inside a loop . Then every mask will be move to specific location (items positions). All the positions (x & y) are in arrays (chartX, chartY). When i execute this code only the 12th item is placed on the stage. Looks strange to me. Can anyone help me please, please ...
for (i=1; i<=12; i++)
{
indexArray = i-1;
_root.attachMovie("myMask" , "mask"+i, 1);
maskName = "_root.mask"+i;
eval(maskName)._x = chartX[indexArray];
eval(maskName)._y = chartY[indexArray];
}
TIA
Natacha
P.S. My english is so bad . Sorry
AttachMovie - Buttons Dont Work Within?
I am dynamically attaching movies clips to another MC. But when i attach them the buttons within dont work! I have a copy of the MC that work just fine if it isnt dynamically attached! WTF! What is wrong here?
Making A Button Work With AttachMovie
I have this code here:
Code:
_root.attachMovie("continue","star1",1);
setProperty("star1",_x,450);
setProperty("star1",_y,50);
"continue" is a button and I place it to the scene with attachMovie. I want to make that button now working that if I click on it that I jump to another frame.
but somehow I dont know how to do that
can anybody help me? I guess its a easy thing!
thanks in advance
AttachMovie And OnRelease Dosnt Work
Hi,
i am new to mx.
I am trying to build my own photo album.
i have a large stage, and a blank mc to load my images into.
i get a list of images from my server, then loop over that list and
attachMovie("blank_mc","image_mc"+i);
then i scale the image to like 10.
i want the image to scale back to 100 with easing when the image is clicked.
i have tried several different ways to attach the blank mc load the image and build a onRelease function for each blank_mc. but nothing seems to work. the only way i have gotten it to do anything close is to createEmptyMovieClip() on the root then attach my blank to the that, then i can put my onRelease on the target_mc not the blank_mc. But i cant tell which image was clicked.
Please help
thanks
heres my creation code:
Code:
for (var i = 0; i"<"tmpArray.length; i++) {
var tmpmc:MovieClip;
tmpmc =_root.target_mc.attachMovie("picmc","pic_mc"+i,_root.getNextHighestDepth()+i,{gID:i});
//this dosnt work here:
tmpmc.onRelease = function (){
expand_mc(tmpmc.gID);//function to move the image around and scale.
};
tmpmc._xscale = 12;
tmpmc._yscale = 12;
}
[F8] Attachmovie Doesn't Work With Hittest?
I have a moving movie clip in my game, and due to some problem caused by an actionscript class I'm using, I can't use hittest on the movie clip itself. So, I tried to attach another movieclip to my original using attachmovie. When I try to hittest the attached clip, it doesn't work either.
I tried it with a rectangle movie clip just to make sure I was doing it right. I discovered that if I attach a rectangle to my original rectangle, hittest doesn't work on the attached clip. However, if I hittest the original clip, the attached clip is used as part of the original clip.
So, is there any way to fix this? All I want is something to move with my movie clip that I can use hittest on.
Can't Get Actionscript To Work On Attachmovie Instance
In the movie (attached to this email) users have to drag an item to one of two boxes. When the student has dragged the item to the correct box, a feedback movie clip appears as a response to this. Also, a second draggable clip appears which also has to be dragged to one of these boxes.
The problem I am having is that the second movie clip I attach from my library wil not function as a draggable clip and I am not sure why.
All my code is on the root timeline.
the .fla is at: http://www.munzamedia.co.uk/2-1-3_activity_temp.fla
How To Make Attachmovie Work With Mask
I am working on one movie that attaching moive to the main time line, but when I add the mask on the top of the attached moive, it does not show up. Do anybody know the reason? Will it be the attached moive always on the top of everything?
Thanks in advance.
AttachMovie In A Parent Movie Does Not Work
Hi
Simple question, but I didn't find the way to do this. I have a clip named Clip1 for this exemple. This Clip1 load an external Clip2. Then when I click a btn in the Clip2 I want to attach a clip that reside in the Clip2 Library to the Clip1 root.
That does not work. Any idea to do that.
Linked clip can't be in the Clip1 library
AttachMovie Doesn't Work Within A Custom Class?
Hey so I've just got some class called foo and foo has a method called bar. Bar wants to use attachMovie and call an ID from the library like so:
ActionScript Code:
class foo {
var myMC:MovieClip;
function foo() { /* ... constructor ... */ }
function bar() {
/* myMC is defined and on stage */
myMC.attachMovie("candy","candy_spawn",myMC.getNextHighestDepth());
}
}
But this, alas does not work.
My FLA uses import foo; and it seems that the class foo cannot access the FLA's library. Yes I have it checked to export for actionscript and export to first frame with identifier "candy"...
Is this just illegal?
AttachMovie Doesn't Work Inside For Loop
I have an xml file with 26 elements representing the alphabet so i can make a glossary (glossary.xml)
I am trying to attach a MC (pointer) for each letter/element in the xml file and add in the appropriate letter to a textbox (alpha_id) inside the MC.
However for some reason attachMovie won't work inside my for loop. Can anyone help me out here?
here's my code:
Code:
//load xml file
var external_xml:XML = new XML();
//ignore all extraneous whitespace
external_xml.ignoreWhite = true;
external_xml.load("xml/glossary.xml");
external_xml.onLoad = function(success:Boolean) {
if (success) {
temp_xml = this.firstChild;
lgh = temp_xml.childNodes.length;
for (i=0; i<lgh; i++) {
var alpha = temp_xml.childNodes[i].attributes.id;
//have also tried 'this._parent' as an experiment - no luck
this.attachMovie("pointer", "pointer"+i, this.getNextHighestDepth());
this["pointer"+i]._x = 40;
this["pointer"+i]._y = 40+(i*(this["pointer"+i]._height+10));
//there is a textbox instance named alpha_id in the mc pointer to accomodate each letter of the alphabet
this["pointer"+i].alpha_id.text = alpha;
}
}else {
trace ("Error");
}
};
AttachMovie() Doesn't Work Properly When Swf Is Loaded Externally
I'm using Actionscript 2 in CS3.
My problem is a little bit hard to explain, so I just try to make it as clear as possible . . .
I have a main swf, which loads another swf using loadMovie, like so:
PHP Code:
loadMovie ("photogallery.swf", _root.empty_mc);
This swf (photogallery.swf) then loads other external movies depending on which button is clicked, in the same way:
PHP Code:
loadMovie ("ranges/obsession.swf", _root.empty_mc);
The other external swfs (such as "obsession.swf" in the example above) are slideshow galleries which load clips from the library using attachMovie(), show them for an amount of time specified by an interval, then attach the next movie over the top.
The code for these is a bit long winded, but looks like this:
PHP Code:
stop();
delay = 9000;
total = 7;
p = 0;
currThumb = "";
prevThumb = "";
names = new Array ("one_mc", "two_mc", "three_mc", "four_mc", "five_mc", "six_mc", "seven_mc");
xPosition = new Array (130, 97, 165, 128, 73, 131, 101);
yPosition = new Array (25, 104, 52, 52, 52, 22, 47);
th_names = new Array (th_one_mc, th_two_mc, th_three_mc, th_four_mc, th_five_mc, th_six_mc, th_seven_mc);
firstImage();
function displayPictures (pic, xPos, yPos)
{
tran_mc.gotoAndPlay("play");
empty_mc.attachMovie(pic, "pic_mc", this.getNextHighestDepth(), {_x:xPos, _y:yPos});
};
function nextImage()
{
if (p < (total-1)) {
p++;
displayPictures(names[p], xPosition[p], yPosition[p]);
currThumb = th_names[p];
currThumb.gotoAndPlay("over");
prevThumb = th_names[(p-1)];
prevThumb.gotoAndStop("up");
picture_num();
slideshow();
}
};
function firstImage()
{
displayPictures(names[p], xPosition[p], yPosition[p]);
currThumb = th_names[p];
currThumb.gotoAndPlay("over");
prevThumb = th_names[(total-1)];
prevThumb.gotoAndStop("up");
picture_num();
slideshow();
};
function slideshow()
{
myInterval = setInterval(pause_slideshow, delay);
function pause_slideshow()
{
clearInterval(myInterval);
if (p == (total-1))
{
p = 0;
firstImage();
} else {
nextImage();
}
}
} ;
So far, so good - the swfs all load OK and the galleries work how they should . . . the first time around. But if you click a button in the main swf that takes you a different part of the timeline, then return to where you were (i.e. loading both lots of external swfs again), the galleries go a bit haywire - the first interval gets very short, much less than the 9000 milliseconds it's supposed to be, and some of the clips in the library don't load.
I put in a series of diagnostic trace statements, and as far a I can tell from that, the code still runs through (i.e. it's not skipping anything), but for some reason it doesn't execute properly - instead of showing the first picture followed by the second, it shows the first, third, fifth; then if you click away and then back again it shows the first, fourth, seventh and so on.
I can't figure this out, because as far as I can tell, the external swfs should just be doing their own thing every time you click on them. There are no functions in the main movie that affect them or anything.
Does anyone have any suggestions or explanations? I would welcome any help that anyone could give. Sorry the post is such an epic . . .
Can't Get Multiple Instances Of Quiz Buttons To Work Using AttachMovie
I have attached two zip files, myVersion & bookVersion.
bookVersion is from the "flash & xml" book source code which is a simple quiz game and although this is written in flash 5, it works without a hitch. The problem is with my version, I can only get one instance of a button at a time, yet the script is identical to the book. I can't get the score counter to work as it returns "NAN", yet this is also identical to the books script .
Hope someone can help, regards.
AttachMovie() Within Another AttachMovie() Created Instance?
I'm still struggling away on my web site, but I've made quite a bit of progress and I think my code has cleaned up quite a bit. I still have the issue of not being able to attach my new content box movie clip when the button is pressed. I am successfully able to load the data for that instance of the tab, and can access the variables. It also is able to run the newContentBox() function inside it with success, but when it tries to run attachMovie(), nothing happens. Could this be a problem with my depth? Or is it my nesting?
I have been thinking about making a global variable for depth that will increment each time anything is created, so every movie clip is guaranteed to be on its own depth. Would this be a solution?
The site can be viewed here.
The source can be viewed here.
All the data files are located in that directory as well.
This is really driving me nuts, and I want to get something solved so I can move onto the submenu creation.
AttachMovie Inside Another AttachMovie
is it possible to attach a movieclip, and then attach another inside of it? i'm trying to load in images via using loadMovie and XML (a little background) i want the image to be dropped in to have a mask applied to it so that the image appears as a rounded rectangle... here's my code for the for loop that attaches the movie clips...
PHP Code:
for (i=1; i<=totalImages; i++) {
attachMovie("multiplebox", "box_"+i, i);
movieNamer=_root["box_"+i];
}
is it possible to attach a movie inside of 'box_"+i'?
AttachMovie Within An AttachMovie? Not Working
So I've finished a project (let's call it Project Blue) where I use attachMovie which references a folder (of swf's) to place each page of the swf. It worked fine. Next, I made a master 'shell' to place this project (among others) into. To do that I used attachMovie again to place Project Blue in the shell.
But now my attachMovie pages for Project Blue won't show up. Does Flash have a problem with using an attachMovie within an attachMovie?
Thanks for any insight on this....
AttachMovie Nested AttachMovie...
I have in the root timeline an empty movie clip that loads other movies inside of it. Using the attachMovie function.
Inside one of these attachMovie clips I have a nest "attachMovie" clip as well but for some odd reason it's not working. Is there anything I should be aware of when nesting an attached movie?
Drop Menu : Rollovers/GetURL In A Movie Don't Work...and The SWF Doesn't Work In FF
My links/rollovers don't work in Mozilla and the dropdown menu part don't work (the rollovers and the getURLs) in any browser.
What's wrong with this??? I think it's something simple.
I've already tried:
Code:
this._lockroot = true;
I also tried writing the AS as:
Code:
one.title.text = "The Text";
one.onRollOver = over;
one.onRollOut = out;
function over () {
this.gotoAndPlay(2);
}
function out () {
this.gotoAndPlay(11);
}
one.onRelease = function(){
getURL("http://www.thelink.com");
}
...didn't work...
I hope someone can help!
Download the: Source File
(Lately I've gotten no help off this site and it's been very depressing because this site people used to be very helpful...I hope someone can change my mind)
This._lockroot Doesn't Work (combobox Components Won't Work)
I have a preloader (preloader.swf) which loads a form (offerte.swf).
I've put the this._lockroot on the "application" timeline on the first frame of the "Flash form application" (offerte.swf).
But the combobox components still won't work.
I had it working before, but suddenly it seemed to stop! Now I can't get it get to work again.
Preview: www.blaak.nl/flash/
This._lockroot Doesn't Work (combobox Components Won't Work)
I have a preloader (preloader.swf) which loads a form (offerte.swf).
I've put the this._lockroot on the "application" timeline on the first frame of the "Flash form application" (offerte.swf).
But the combobox components still won't work.
I had it working before, but suddenly it seemed to stop! Now I can't get it get to work again.
Preview: www.blaak.nl/flash/
LoadMovie Work But Send Variable Not Work On Mac.
Hi!
I have many swf files that I want it link to specify frame.
AT Level0(bg.swf ): I set two variable as glob_marker, glob_scene for keep frame label and scene from Level5 for load Level8 and goto that label. action at frame be:
glob_scene = "";
glob_marker = "";
loadMovieNum ( "movie1.swf", 5 );
Inside Level5(movie1.swf): I set action to buttons be:
on (release) {
_level0.glob_scene = "5";
_level0.glob_marker = "5-1";
loadMovieNum ("movie2.swf", 8);
}
Level8(movie2.swf ): I set action to first frame at root be:
dis = _level0.glob_scene;
if (dis eq "5") {
gotoAndPlay ("IC", "LL");
} else {
gotoAndPlay (3);
}
And Level8(movie2.swf ): Inside "IC scene" I set action to first frame be:
display = _level0.glob_marker;
if (display eq "5-1") {
gotoAndPlay ("IC1", "IC1");
} else {
loadMovieNum ("orher.swf", 20);
gotoAndPlay ("IC1", "IC1-1");
}
Everything work fine on PC.
It go to scene and label right.
But for Macintosh it not go to scene and label (movie2.swf) as I want, it go to first scene and first frame.
(Everything play on CD by have projector from Flash Not preview with Browsers)
I sorry for my english. Thank you.
Including A Font Don't Work For IE 6.0, And DOES Work For Netscape?
This is weird,
I included a font into Flash 5 and when I view the flash content on another pc (that don't have the included font installed) with Internet Explorer 6.0 it gives me some ugly other font, and for Netscape 4.0 it works perfect!
Does anyone know about this problem?
Please reply if you know something that could solve the problem
Thank you
Why Would Flash Movie Work At Home & Not At Work?
I've verified the javascript works. I verified that my ActionScript works - at home anyway - in Firefox and IE6. When I brought my code from home and ran it on my work computer, the Javascript function fails to execute in Firefox! Firefox! Then, the JavasScript function fails to execute in IE7, which I halfway expected...
The strange part in all this is that when I use Firefox's IE view plugin (views Internet Explorer as a tab in Firefox), the Flash movie is fully active - it calls the javascript function as intended, The hyperlinked movieclips open new pages as expected, etc. Why is this?
I need this movie to function here at work the way it functioned at home! I know that ActionScript works the way it should where ever you use it... The JavaScript isn't to blame - I know it works in all the browsers I use... In both cases, home and work, I've ran all my files (HTML, SWF) from the same directory, so I'm not worried about conflict between realative and abolute paths...
Does it have something to due with Flash security settings? Does it have something to do with the HMTL object tags I'm using? That's the only thing I can think of.
This is work-related. Please help!
Attach Code
>>The AS2 is simple:
import flash.external.ExternalInterface;
closeDiv_btn.onPress = function() {
ExternalInterface.call("disappear");
}
>>The javascript is lenghtly so I won't show it here, but I've verified that the function works and is properly named "disappear()".
>>Here's the HTML object tag:
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0"
width="500" height="300" title="Hover Ad">
<param name="allowScriptAccess" value="always" />
<param name="movie" value="myMovie500x300.swf" />
<param name="quality" value="high" />
<embed src="myMovie500x300.swf" quality="high"
pluginspage="http://www.macromedia.com/go/getflashplayer"
type="application/x-shockwave-flash" width="500" height="300"></embed>
</object>
Edited: 05/30/2007 at 12:57:31 PM by JaeWebb
Smoothing Doesn't Work It Oughta Work
Hello!
I am trying to develope this website:
http://anarchy.primalinsanity.com/~villain/nma.rar
Its smoothing effect, however, has mysteriously disappeared. It is only enabled in authoring mode, not if I export the movie. I've tried everything to re-enable it:
1) Changed formats from JPG to PNG
2) Library > Bitmap Properties > Allow smoothing
3) File > Publish Settings > Smooth
But nothing seems to work
Thanks everyone,
Johann
Guestbook & Counter Work Don't Work On Server
I've created a counter and a guestbook with flash and php using a txt file to store information. it all worked fine when i tested it on the tripod.de server with one of my accounts. however it doesn't work if i load it up on another account on www.tripod.de. i did activate php on this acount but that's not the problem...
i'll give u both links, ...
here ithe guestbook works
debwebflash guestbook
here the counter works:
debwebflash counter
here i want it to work!
donboscoduisburg
well this last page is in german, so to get to the guestbook u have to click on the link "Gästebuch" further down on the list on the left. the counter is on the left and doesn't work eigther. both don't write into the .txt file for some reason.
thanks, hope someone can help.
Got My Slider Work Once, Now I Need It Work Everytime..
peepz,
my following slider script slides only once to the desired position, but i want it to do it every time.
if i press the button it moves (and eases to the xposition of the slider - 119), but if i pres agina it will not move again, i want to let it move agian 119 pixels:
Code:
stop();
slider = this._parent._parent.mcCollectionSliderTop;
finalx = this._parent._parent.mcCollectionSliderTop._x - 119;
this.mcVolgende.onPress=function(){
this.onEnterFrame=function(){
slider._x += Math.round((finalx-slider._x)/5);
}
}
thanks for all of your help
Hittests Work/Dont Work
Ok, I think I may know the problem. I have a movie clip called "mario_mc". THen I have a background called "background_mc". Inside I have coins, blocks, and boxes. The ONE box is called "box_mc" and the ground blocks are all called "groundBlock_mc". Now when I do:
Code:
trace (mario_mc.hitTest(background_mc.groundBlock_mc));
it says "false". But when i do :
Code:
trace (mario_mc.hitTest(background_mc.box_mc));
Is it because there is more than one ground block? The .fla is attached.
Note: Mario copyrighted of Nintendo of America.
(fmx) Button1 Work - B 2 Not Work - B 3 Work? W
hi,
I'm trying to do a web site with this tutorial
http://www.kirupa.com/developer/mx2004/transitions.htm
but i have little problem button1 works and button 3 works!
why button 2 not working?
here is fla and swfs http://geocities.com/dutch_delusion/fq.html
Thanks
AttachMovie
I’m using the attachMovie command and I need to remove the attached movie. I’ve tried unloadMovie, removeMovieClip, delete, and unloadMovie. I can get the clip to do anything else. A friend suggested I try to delete a layer but I don’t know how. Oh this is the important part I need the script to be in the Movie Clip.
Thanks in advance,
Slow21969
AttachMovie HELP
Okay guys, I've been trying this code for literally 18 hours, with no luck at all. I know for some of you this is going to be a walk in the park, so please help me out.
All I want to do is have a blank stage. On frame 1 of this main stage, I want some sort of code that will attachMovie. I can get through there just fine. My problem is this. I to dynamically generate different pics.
I really don't care HOW you get the different pics in there, but I want my stage to start out blank, so I think the only way to do it is with attachMovie. I have a zip file at: http://www.skycastleprod.com/demo/help.zip where you can see something I made. In that file, I generated a button with different url links that it will call when it is clicked, and it also has a textbox that displays different words for each box. The thing is, that file used ONE smartclip, and that's it. With one smartclip I was able to generate buttons with different URLs, and a textbox that has different sayings. WHY CAN'T I GENERATE DIFFERENT PICTURES?!?!?!?!?!? this is driving me insane. I've lost so much sleep coz of this, and it's not even part of a project. It's become more of a personal thing now #$%#$%@$. PLEASE HELP
Riki
AttachMovie
How come when using a attachmovie action, it works fine and the attached MC loads, but doesn't when I save the file and publish the settings.
.attachMovie=help
i'm trying to make an image slider, first i duplicate and move the movie clip by getting coordinates form a dragged empty mc, setting an inverse motion, so if the mouse goes up the mc and duplicated mcs go down. It all works very well, until i try to attach movies to the duplicated movie clips. Is this possible to do? can i attach movie clips(in this case each containing a picture) to duplicated ones??
thanks in advance.
supakoma
AttachMovie
I've got a little problem because i don't know the exact syntax for adressing targets in "attachMovie" or in general.
The problem is in these lines:
Code:
if (k<20) {
star1.attachMovie(star_mother, _root.anfang_ani["star"+k], k );
_root.anfang_ani["star"+k].speed = 15;
for (i=2; i<k; i++){
if(_root.anfang_ani[star1].diffy >= 1500 && _root.anfang_ani["star"+i].diffy >= 1000){
setProperty (_root.anfang_ani[star1], _visible, 0 );
setProperty (_root.anfang_ani["star"+i], _visible, 0 );
gotoAndPlay("start");
}
}
}
else{
gotoAndPlay("start");
}
It'd be extremely nice if somebody could take a look and remind me of the correct syntax or paths.
Thanks in advance
Using Mc.attachMovie() Without The Mc. -Don't Do It
I just spent a lot of time debugging a game for something really stupid I did and I learned something new about mc.attachMovie().
You can do this: attachMovie()
instead of
_root.attachMovie
Don't do it. Always include specifically the movie this new attached movie is attaching to, even if it is only the original root movie you are working within.
If you don't specify the MC parent that will own it, Flash 5 (I don't know about other versions) will assume the parent for you. You would think it would be what ever _root movie the script lies in but it is not always true. If you have attached other movies on the fly, it can pick up on another attached movie that is currently recieving events.
-Wade
AttachMovie
I have a movie clip called Circle_01 its placed on the main timeline.
I want to keep creating new instances of this but cant seem to even get one to work.
Here is the code im using???????????
_root.attachMovie("_root.Circle_01", "_root.Circle_2", 1);
_root.Circle_2._x = 150;
_root.Circle_2._y = 150;
_root.Circle_2._alpha = 1;
_root.Circle_2.play();
|