Getting Load Movie To Work
Problem: I am trying to use the loadmovie command.. I have two buttons inside a movie clip with one button reading install and another remove..What i want to happen is when I press the install button the install movie will load and then the button should read remove..When I click the remove button it will load the remove.swf movie and the button will go back to install..
where I get snagged: the movie loads but the the button and background disappears...Why is that??? I want to buttons and background to still appear.
Here is the code I used on the button. on (release) { _root.loadMovie("battery.swf","emptypic1"); this.gotoAndStop("remove");
}
Any suggestions anyone??????
FlashKit > Flash Help > Flash Newbies
Posted on: 09-22-2004, 04:03 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Load Movie Ont Work
Hi,
My problem is I am trying to simply load an .SWF file over an existing .SWF file from a button, using
on (release) {
loadMovieNum ("new.swf", 1);
}
It works fine when I use control, test movie but it doent work when I publish it, it just jumps to a blank screen.
Pleeese Help!!!
Buttons Don't Work After Load Movie
Hello all,
I've have this simple .swf which contains one MC and one button. When you start the .swf you only see the button. Click on the button to make the MC visible. This works fine. Now I want timport the .swf into another animation. I can import it no problem. Only now when I click the button nothing happens.
Does anybody know what this might be.
Thanks
Movie Load Doesn't Work
I have developed a lesson where the root movie is like a tv set where all the controls for volume and changing channels (ie topics) are contained. When the user clicks on a topic button, the root movie loads the topic into a child movie holder and displays it "on the screen".
I developed this on my laptop and everything works fine. I then transferred it to my pc, where I will upload it to my website. The problem is, on my pc, it won't load any of the topics! Here are some additional clues to the dilemma:
1. When I run it in test mode, it DOES load the topics..........it just won't do it when the swf is running separately.
2. The original script, which was for loading locally (ie no preloader needed) was replaced with the current script (again this script works fine on the laptop and also on the pc in test mode). Just for the heck of it, I remmed out the new script and unremmed the old and THAT WORKS TOO!
So there is something screwed up with the new code and as it works on one station and not the other, I'm thinking this is maybe a flash player version problem?? Both the PC and laptop are set to publish at flash player 7 and use AS 2.0. (actually all publish settings are the same).
Here's the script:
_root.preIT._visible = true;
var my_content:MovieClipLoader = new MovieClipLoader();
var myContentListener:Object = new Object();
myContentListener.onLoadProgress = function(target_mc:MovieClip, loadedBytes:Number, totalBytes:Number) {
_root.pbarPCT = String(Math.round((loadedBytes/totalBytes)*100))+" %";
_root.preIT.pbar0.pbar1._width = Math.round((loadedBytes/totalBytes)*574);
};
myContentListener.onLoadComplete = function(target_mc:MovieClip) {
_root.preIT._visible = false;
};
myContentListener.onLoadError = function(target_mc:MovieClip, errorCode:String) {
trace("*********First my_mcl instance*********");
trace("ERROR CODE = "+errorCode);
trace("Your load failed on movie clip = "+target_mc+"
");
};
my_content.addListener(myContentListener);
//trace(_root.loTitle+_root.topicFile);
my_content.loadClip(_root.loTitle+_root.topicFile, _root.content_mc);
//end preloader code
//loadMovie(_root.loTitle+"/"+_root.topicFile, _root.content_mc);
_root.splashScreen_mc._visible = false;
NOTE: The currently unremmed my_content.loadClip line is what doesn't work when the swf is run by itself. The currently remmed out loadMovie command however, works fine. I of course need to have the preloader when this thing is run on the web so that doesn't do me much good (that the latter one works).
Thanks for the help!
Edited: 01/13/2007 at 05:32:57 AM by IwannaFlashU
Load Movie To Different Levels Do Not Work With Netscape 4.5
Hi,
I have a main movie and can load many external swf into various levels. It can be played correctly online if I used IE5.
The problem is that some of the external movies that use the following script on a button did not work.
on (press) {
loadmovienum (external.swf, 2);
unloadmovienum (3);
}
Will Netscape 4.5 be different from IE5 in terms of viewing Flash 5 movie?
Anyone knows where is the problem that I encountered?
Thanks
net2
Why Won't This Simple Thing Work? Load Movie
i really hope someone can help with this.
i have a main movie, with a button that tells another movie to load into a movie clip ("main_drop") in the main movie.
then, i want to tell the loaded movie clip to play a specific frame. i just cannot get this to work.
on (release) {
loadMovie ("movie.swf", "main_drop");
if (loadedbytes == totalbytes and totalbytes >1) {
tellTarget ("main_drop") {
gotoAndPlay ("two");
}
}
}
has anyone got any ideas?
it seems to be such a simple thing i'm trying to do.
thanks,
gina
Actionscript Doesn't Work When Load Movie
I made an image scroller and it works fine. But then when I load the scoller in a movieclip in another flash file, it doesn't work, the buttons click but nothing happens. It works if I load it in the root level. but when I put the loadmovie actionscript within a movieclip the scroller does not work. Hope this makes sense.
Thanks
Load Movie Doesn't Work In Netscape
We have a Flash movie that works fine in netscape but at the end of it we have a button with a Load Movie action on it so that when you click the button it loads a new movie. This works fine in IE but not not in Netscape.
Any ideas why not?
[Using Flash MX]
Load Movie Does Not Work In Safari But Works In IE
Please help:
I used the load movie behavior in my swf file. When I test the button in Safari, the link does not work. However, it works in Internet Explorer. Why could this be.
This is the script I used:
on (release){
loadMovieNum ("
Select Movie From Php Doesnt Work In IE If I Load From Sub..
Hey, I got some problems with selecting movies from sub folders when using IE, if I write this code here the file will play:
Code:
<param name="FlashVars" value="file=move.flv" />
But if I write this code IE wont even get the file:
Code:
<param name="FlashVars" value="file=folder/movie.flv"/>
This is the whole php code used:
Code:
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" allowScriptAccess="sameDomain" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="309" height="278" >
<param name="allowScriptAccess" value="sameDomain" />
<param name="movie" value="playervideo.swf" />
<param name="quality" value="high" />
<param name="FlashVars" value="file=folder/movie.flv"/>
<embed src="playervideo.swf" FlashVars="file=folder/movie.flv" quality="high" width="309" height="278" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
</object>
Could there be a good explanation why IE acts like this?
Load Movie Wont Work Untill The Second Time....
heres the site i'm working on-
http://home.mchsi.com/~cinumann/
when you go to the pertfolio, and click on one of the links, it is supposed to load a seperate swf with pics and a description in it, but instead it only loads bits and peices of it, and you have to go back and click a second time to get it to load properly...
anyone know what the problem could be?
Anim FX Load Movie In Level 1 Doesn't Work
I am trying to load an effect from Anim FX to Flash though the loadmovie command. It works fine with level 0(replaces the original movie)but it doesn't seem to work with other levels. Load movie on a particular movie clip target doesn't seem to work either. Any suggestions?
Anim FX Load Movie In Level 1 Doesn't Work
I don't know if you are aware or have used Anim FX at all, I hope you have!
I am trying to load an effect from Anim FX to Flash though the loadmovie command. It works fine with level 0(replaces the original movie)but it doesn't seem to work with other levels. Load movie on a particular movie clip target doesn't seem to work either. Any suggestions?
Anim FX Load Movie In Level 1 Doesn't Work
I don't know if you are aware or have used Anim FX at all, I hope you have!
I am trying to load an effect from Anim FX to Flash though the loadmovie command. It works fine with level 0(replaces the original movie)but it doesn't seem to work with other levels. Load movie on a particular movie clip target doesn't seem to work either. Any suggestions?
Swf Not Working Properly Via Load Movie (used To Work Prefectly)
Hi all, have a very weird problem, pls visit my site at www.dreamance.com on the bottom right panel, scroll down and click on the ¡°Happy New Year¡± entry for it to load. You see the problem. My fish is being broken up¡_
Now take a look in this link http://www.dreamance.com/1000/files/newYear/entry.swf
It work perfectly (just a little slow).
The problem is that it used to work in both links. Currently, it only work while viewing alone, not longer via load movie into another swf. I dunno this had happen for how long but I suspect it had something to do with flash 7 player. Anyone can shine any light in this problem?
Million Thanks!
Chup
Drop Down Menus And Making Them Work With Load Movie.
Thank for your help people...
Im new here so please bare with me..
Thank for your help people...
Im new here so please bare with me..
OK I down loaded an fla tutorial on drop down menus. Its basically a movie with the main menu button and the additional menus buttons with the invisible button within the movie.
The drop down actions and menu work. BUT I cant make the pages/movie.swfs Ive called for in the scrpit to switch.
Basically I am putting a load movie/tell target to change my pages.
What am I doing wrong? is it not possible since the script is inside the movie and not on the movie button?
heres the .fla files... Ill put the one Ive DL and the one I created maybe I did it wrong/
Please let me know..
Thanx- :O)
Its basically a movie with the main menu button and the additions menus buttons with the invisible button inside the movie.
The drop down actions and menu work. BUT fro some reason I cant make the pages Ive called for in the scrpit to switch.
What Im basically doing is putting a load movie./ tell target to change my pages.
What am I doing wrong? is it not possible since the script is inside the movie and not on the movie button?
heres the .fla file... Ill putb the one Ive DL and the one I created maybe I did it wrong/
Please let me know..
Thanx- :O)
Drop Down Menus And Making Them Work With Load Movie.
Thank for your help people...
Im new here so please bare with me..
Thank for your help people...
Im new here so please bare with me..
OK I down loaded an fla tutorial on drop down menus. Its basically a movie with the main menu button and the additional menus buttons with the invisible button within the movie.
The drop down actions and menu work. BUT I cant make the pages/movie.swfs Ive called for in the scrpit to switch.
Basically I am putting a load movie/tell target to change my pages.
What am I doing wrong? is it not possible since the script is inside the movie and not on the movie button?
heres the .fla files... Ill put the one Ive DL and the one I created maybe I did it wrong/
Please let me know..
Thanx- :O)
Its basically a movie with the main menu button and the additions menus buttons with the invisible button inside the movie.
The drop down actions and menu work. BUT fro some reason I cant make the pages Ive called for in the scrpit to switch.
What Im basically doing is putting a load movie./ tell target to change my pages.
What am I doing wrong? is it not possible since the script is inside the movie and not on the movie button?
heres the .fla file... Ill putb the one Ive DL and the one I created maybe I did it wrong/
Please let me know..
Thanx- :O)
Load A Movie To Another Level And The Buttons In Base Level Still Work..
Hello,
Ok Im loading movies into level 95. The problem is the movie at the base has buttons in it and they are still active through the movie that is loaded at lvl 95. So to fix this I made one large button and made the movie at lvl 95 dragable. The only issue with this method is now your cursor looks like it is always active. So has anyone figured out a way to block buttons that are at the base level if you load into a upper level?
Thanx
Robert
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)
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
Does Load Movie LOAD Entire Movie, How Can I Stream It?
i have a load movie loading my music. I have a preloader at the front of my music, but i dont think the preloader is working on load movie. Does the load movie command download the whole movie into cache, or does it just start playing the movie.
IE.. if i have a 5 meg mp3 that i wanna dled and listen to, is it just downloading the whole thing, until the movie is loaded, and then playing, or is it streaming it in?
i tried to make a preloader for it, but it looks like the preloader just instantly zooms across... how can i show status of this movie loading?
thanks
External Movie Will Not Load, But Does Load When I Use 'test Movie'?
I had my external movies loading wonderfully then all of a sudden one of the externals (that I use 'loadmovie' on) will not load? The weird thing is that when I test my movie using 'test movie' in my main movie, it works fine, but when I go to my staging (test) site: www.gbebos.com/Liz/Hit.htm the one movie in 'Earth elements' page will not load, but the other movies i.e. 'Crystal Elegance' and 'Silver Essence' work fine. I made sure that the .swf and .html were transfered to the domain and they are both there.
Any help for this newbie would be greatly appreciated!
Thanks again to ya all at Flashkit!
gbebos
How Do I Stop My Second Movie Load Clearing My First Movie Load?
Hi,
Working on a home page where a swf movie loads and plays on the timeline.
The problem is when the second swf movie loads and plays further along the timeline the first swf movie disappears...I want it to remain on my stage!
Any ideas?
Cheere Jim
Here is the code I'm using to load the swf movies:
this.createEmptyMovieClip ("emptyClip",this.getNextHighestDepth());
emptyClip.LoadMovie(...swf");
Load From Text, In A MC, I Can't Get It To Work, Help
What I am trying to do is be able to update a news section via a text file. In order to have it scroll, I must put it in a movie clip. When I put it in a movie clip, I cannot get it to recognize my variable from my text file. I have tried loading the text file and then using the target command to go to the movie clip in which I am using the variable, but that didn't work. I have no clue what I am doing, but I have been able to load a text file on the main stage on a textbox that wasn't in a movieclip. Any help would be appreciated.
Thanks,
-Brady White
Sorry for the double post, I posted just before this one, but I think it would get more replies and also I have made my question more direct now that I realize the problem I face.
Help With Txt Load From Server?i Cant Get It Work
this is my first site that im doing so pretty much im looking at other people examples and trying to figuer out how they do it.
N-E-Ways
i just recently look into scroll bar txt file loading mu problem is with the external text file and i got a example but i cant get it to work properly. in my computer it works fine (since it is all local) but now i have i change the script to get the file from the internet and it doesnt wanna work. what am i doing wrong???
this is the script that i use to get the txt file.
loadVariablesNum ("http://home.collegeclub.com/bluepitbull/files/txt/news.txt", 0);
----------
this is the old one that works fine
loadVariablesNum ("news.txt", 0);
help please
heres the new link to my file
http://home.collegeclub.com/bluepitb...s/3pitbull.zip
XML Load Won't Work With Flash 8
Hey everyone,
I have a little problem. I want to import some variables from an xml file, and format them using the following AS. Only problem is it all works fine when I export the movie as Flash 6, but as soon as I export as a flash 8 movie it no longer works. I realise there's probably some differences in AS (I've tried exporting as AS1 and 2), but I just can't find them. Can anyone help?
ActionScript Code:
// The first step is to activate the XML object
headlineXML = new XML();
/*
With the XML Object now active you must now load an XML foramtted document.
Any DTD or XLS formatting will be ignored.
*/
headlineXML.onLoad = myLoad;
headlineXML.load("headlines.xml");
// Before proceeding to far into the program, make sure the XML document has loaded
// Extract information from the XML file
function myLoad(ok) {
if (ok == true) {
Publish(this.firstChild);
}
}
function Publish(HeadlineXMLNode) {
if (HeadlineXMLNode.nodeName.toUpperCase() == "BROADCAST") {
content = "";
story = HeadlineXMLNode.firstChild;
while (story != null) {
if (story.nodeName.toUpperCase() == "STORY") {
lead = "";
body = "";
URL = "";
element = story.firstChild;
while (element != null) {
if (element.nodeName.toUpperCase() == "LEAD") {
lead = element.firstChild.nodeValue;
}
if (element.nodeName.toUpperCase() == "BODY") {
body = element.firstChild.nodeValue;
}
if (element.nodeName.toUpperCase() == "URL") {
URL = element.firstChild.nodeValue;
}
element = element.nextSibling;
}
content += "<font size='+2' color='#3366cc'><a href='"+URL+"'>"+lead+"</a></font><br>"+body+"<br><br>";
txt.htmltext=content;
}
story = story.nextSibling;
}
}
}
Why Does Xml Or Load Vars Or Anything Not Work?
this code is inside a button's on(release)
var stuff:LoadVars = new LoadVars();
var resultStuff:LoadVars = new LoadVars();
stuff.name = _global.name;
stuff.sendAndLoad("http://someWebsite.php stuff",resultStuff,"POST");
stuff.onLoad = function(success)
{
trace(resultStuff.something);
}
this never works! moreover, if i put the onLoad function on the top it still doesn't work! i have to use LoadVars.prototype.onLoad. can someone please explain me why? thanks.
it only traces if i move to another frame, why that?
Load Mp3 Doesnt Work
I am trying to load an mp3 externally like in the tutorial, but i get a download prompt. I dont want a download prompt. The way I understood it, the mp3 is loaded and played, and not downloaded. Am I missing something in the tutorial? I currently have it in its own layer:
heres my code:
Code:
mySound = new Sound();
mySound.loadSound("music.mp3",true);
If im correct it should play while the .swf is loading. I have it preloading, if that makes any difference.:-
thanks
~J
3d Carousel Load Swf Do Not Work
Hi all
I'm a flash beginner and I have used 3 of your flash examples , "3D carousel" +"sending Mail with PHP"+"External SWF Preload" like this:
The 3D carousel is the main menu, by selecting an item it reads a XML file and preload a swf (like explained in the tuto "External SWF Preload " ) file like your example:"sending Mail with PHP"
My problem is:
all SWF works without any problem separately, but not when they are called by the 3d Carousel, they are correctely preloaded but they do not run, for example the swf from the tuto " sending Mail with PHP" do not send Email when clicking onto "send".
Many thanks for your help
this is the code from the Carousel:
Code:
stop();
import mx.utils.Delegate;
import mx.transitions.Tween;
import mx.transitions.easing.*;
var mcl:MovieClipLoader = new MovieClipLoader();
var mclL:Object = new Object();
var numOfItems:Number;
var radiusX:Number = 400;
var radiusY:Number = 75;
var centerX:Number = Stage.width / 2;
var centerY:Number = Stage.height / 2;
var speed:Number = 0.02;
var perspective:Number = 130;
var home:MovieClip = this;
theText._alpha = 0;
var tooltip:MovieClip = this.attachMovie("tooltip","tooltip",10000);
tooltip._alpha = 0;
var xml:XML = new XML();
mclL.onLoadProgress = function(target,loaded,total) {
loader.percent.text = Math.round((loaded/total) * 100) + "%";
}
mclL.onLoadInit = function() {
loader._visible = false;
loader.percent.text = "";
}
mcl.addListener(mclL);
mcl.loadClip("1.swf",holder);
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.angle = i * ((Math.PI*2)/numOfItems);
t.onEnterFrame = mover;
t.toolText = nodes[i].attributes.tooltip;
t.content = nodes[i].attributes.content;
t.icon.inner.loadMovie(nodes[i].attributes.image);
t.r.inner.loadMovie(nodes[i].attributes.image);
t.icon.onRollOver = over;
t.icon.onRollOut = out;
t.icon.onRelease = released;
}
}
function over()
{
//BONUS Section
var sou:Sound = new Sound();
sou.attachSound("sover");
sou.start();
home.tooltip.tipText.text = this._parent.toolText;
home.tooltip._x = this._parent._x;
home.tooltip._y = this._parent._y - this._parent._height/2;
home.tooltip.onEnterFrame = Delegate.create(this,moveTip);
home.tooltip._alpha = 100;
}
function out()
{
delete home.tooltip.onEnterFrame;
home.tooltip._alpha = 0;
}
function released()
{
loader._visible = true;
mcl.loadClip(t.content,holder);
//BONUS Section
var sou:Sound = new Sound();
sou.attachSound("sdown");
sou.start();
home.tooltip._alpha = 0;
for(var i=0;i<numOfItems;i++)
{
var t:MovieClip = home["item"+i];
t.xPos = t._x;
t.yPos = t._y;
t.theScale = t._xscale;
delete t.icon.onRollOver;
delete t.icon.onRollOut;
delete t.icon.onRelease;
delete t.onEnterFrame;
if(t != this._parent)
{
var tw:Tween = new Tween(t,"_xscale",Strong.easeOut,t._xscale,0,1,true);
var tw2:Tween = new Tween(t,"_yscale",Strong.easeOut,t._yscale,0,1,true);
var tw3:Tween = new Tween(t,"_alpha",Strong.easeOut,100,0,1,true);
}
else
{
var tw:Tween = new Tween(t,"_xscale",Strong.easeOut,t._xscale,100,1,true);
var tw2:Tween = new Tween(t,"_yscale",Strong.easeOut,t._yscale,100,1,true);
var tw3:Tween = new Tween(t,"_x",Strong.easeOut,t._x,200,1,true);
var tw4:Tween = new Tween(t,"_y",Strong.easeOut,t._y,320,1,true);
var tw5:Tween = new Tween(theText,"_alpha",Strong.easeOut,0,100,1,true);
theText.text = t.content;
loader._visible = true;
mcl.loadClip(t.content,holder);
var s:Object = this;
tw.onMotionStopped = function()
{
s.onRelease = unReleased;
}
}
}
}
function unReleased()
{
mcl.loadClip("",holder);
loader._visible = false;
//mcl.loadClip("video.swf",holder);
//BONUS Section
var sou:Sound = new Sound();
sou.attachSound("sdown");
sou.start();
delete this.onRelease;
var tw:Tween = new Tween(theText,"_alpha",Strong.easeOut,100,0,0.5,true);
for(var i=0;i<numOfItems;i++)
{
var t:MovieClip = home["item"+i];
if(t != this._parent)
{
var tw:Tween = new Tween(t,"_xscale",Strong.easeOut,0,t.theScale,1,true);
var tw2:Tween = new Tween(t,"_yscale",Strong.easeOut,0,t.theScale,1,true);
var tw3:Tween = new Tween(t,"_alpha",Strong.easeOut,0,100,1,true);
}
else
{
var tw:Tween = new Tween(t,"_xscale",Strong.easeOut,100,t.theScale,1,true);
var tw2:Tween = new Tween(t,"_yscale",Strong.easeOut,100,t.theScale,1,true);
var tw3:Tween = new Tween(t,"_x",Strong.easeOut,t._x,t.xPos,1,true);
var tw4:Tween = new Tween(t,"_y",Strong.easeOut,t._y,t.yPos,1,true);
tw.onMotionStopped = function()
{
for(var i=0;i<numOfItems;i++)
{
var t:MovieClip = home["item"+i];
t.icon.onRollOver = Delegate.create(t.icon,over);
t.icon.onRollOut = Delegate.create(t.icon,out);
t.icon.onRelease = Delegate.create(t.icon,released);
t.onEnterFrame = mover;
}
}
}
}
}
function moveTip()
{
home.tooltip._x = this._parent._x;
home.tooltip._y = this._parent._y - this._parent._height/2;
}
xml.load("icons.xml");
function mover()
{
this._x = Math.cos(this.angle) * radiusX + centerX;
this._y = Math.sin(this.angle) * radiusY + centerY;
var s = (this._y - perspective) /(centerY+radiusY-perspective);
this._xscale = this._yscale = s*100;
this.angle += this._parent.speed;
this.swapDepths(Math.round(this._xscale) + 100);
}
this.onMouseMove = function()
{
speed = (this._xmouse-centerX)/4500;
}
Chromeless Windows That Open On Movie Load Or Load Of Html Page (Flash Ad Kit)
Hi guys,
I was wondering if someone could help me out in creating these flash ads that appear out of nowhere. I see them mostly on rediffmail, yahoo and about.com.
I know how to create a popup window on button click, but how you do that without a button.
There's another dimension of ads nowadays. They are the transparent ads. They really look cool. Could someone with this knowledge pleeeeeeeeese help me out. I urgently need to create these ads.
Regards,
designable
Chromeless Windows That Open On Movie Load Or Load Of Html Page (Flash Ad Kit)
Hi guys,
I was wondering if someone could help me out in creating these flash ads that appear out of nowhere. I see them mostly on rediffmail, yahoo and about.com.
I know how to create a popup window on button click, but how you do that without a button.
There's another dimension of ads nowadays. They are the transparent ads. They really look cool. Could someone with this knowledge pleeeeeeeeese help me out. I urgently need to create these ads.
Regards,
designable
Load JPG's Via LoadMovie Doesn't Work
Im trying to load JPG's via loadMovie("http://mydomain.com/twin.jpg", "_root.myMovieClip");
the .swf is in a diferent domain i think this is the problem
but it works when i tell it to load an other .swf file.
so whats the big deal? i can't load JPG's from a diferent URL?
What i want to do is load this JPG's files every 10Secs because i didn't find the way to make the live stream with liveCam = camera.get();
myCam.attachVideo(liveCam); <--- i know this way only works locally and when u publish the movie it says allow "local" to access blah blah blah.
but i've visited a few sites that says Allow "domain.com" to acces your camera blah blah blah.
http://pilotvideo.com/NewFiles/Compression.html
But if anyone can tell me how i can load the JPG's from URL i'll be pretty happy, thanks in advanced =)
Can't Get Load Into Empty Movieclip To Work In 5
I am trying to load a .swf into a movie clip instead of onto a level. you'd think this was simple, but I must be missing something
here is my script
on (release) {
loadMovie ("pkgzoom.swf", "image");
}
looks right, then why won't it work?
Load Buttons With LoadMovie Does Not Work
Hi all,
Well I've spend the last hour and a bit looking at old threads for swonking. Did not find what I was looking for, nevermind here the brain teaser (or not):
I am creating a menu with buttons that I load from an external swf. I copy a mc and then load the button. On my machine it all goes well but when uploaded, sometimes (not always, but that has to do with the server cache I think) only one of the buttons is displayed. Once moving over them they start appearing. So I thought it has to do with loading the swf several times in a very short space. Now I could solve it easily by including the button in my lib, but then I lost my flexibility. Has any of you got an idea of how to solve it. working with getBytesLoaded somehow does not work as it returnes the size of the whole movie instead of the target object. So help me please as I am tearing my hears out and I am bold afterall so it starts hurting
greetingz
Here some code
ActionScript:--------------------------------------------------------------------------------
loadMovie("button2.swf","menu1.menuhead.menuclip_b g");//1st menu. This menu1 is already on stage and is the original to be copied
maxMenus=Number(dat.numMenus) + 1;
xnext=0;
for (j=2;j<=(maxMenus-1);j++){
duplicateMovieClip("menu1","menu"+j,j);//the variables i.e. the swf are not copied with it! need to load these saparate
xpos=getProperty("menu"+(j-1),_x);
ypos=getProperty("menu"+(j-1),_y);//get pos from previous menuclip
ynext=ypos+h1;//h1=height menu
ysoll[j-1]=ynext;
//trace("ysol"+(j-1)+"= "+ ysoll[j-1]);
xnext=xpos+0;
setProperty("menu"+j,_y,ynext);
setProperty("menu"+j,_x,xnext);
loadMovie("button2.swf","menu"+j+".menuhead.menucl ip_bg");
gbt=getBytesTotal("button2.swf");trace("gtb="+gtb) ;
gbl=0;
while (gbl<gbt){gbl=getBytesLoaded("button2.swf"); //this takes the totalbytes of the whole movie not the button2.swf
trace("loading for menu"+j);}
}
--------------------------------------------------------------------------------
The script has to be F5 compatible
ps the button2.swf has only two frames and is 6k big.
How To Load A Large Text And Work With It?
I hope this is possible with flash, and doesn't require something like coldfusion, but here it goes:
I want to load a text file with a bunch of entries like this:
APPLE red round eat
PEAR green oval eat
BASEBALL white round play
FRISBEE red round play
in the flash animation, if a user clicks "RED" it will list all things that are red, so: APPLE and PEAR
but if they choose round, it will list APPLE BASEBALL and FRISBEE.
basically, it will reproduce each line based on the the fact that the line contains one of the 'key' terms.
CAn this be done with minimal pain in flash or should i take it upon myself to learn another platform??
thanks kindly
djshtr@hotmail.com
Load Vars In If Statement = No Work
I a load Vars object inside of an if statement the does not work. The second that I comment out the if statement the code works just fine. The thing is the if statement works because I ran some traces to check that the code is running inside of it. Any help would be appreciated, here is the code:
on (press) {
if (selectionClip.selectedXML.firstChild.childNodes.l ength>0) {
id = new Array();
rationaleS = new Array();
for (i=0; i<selectionClip.selectedXML.firstChild.childNodes. length; i++) {
id[i] = selectionClip.selectedXML.firstChild.childNodes[i].attributes.id;
}
submitData = new LoadVars();
submitData.idList = replace(id.toString(), ",", "|");
submitData.countryId = _root.countryId;
submitData.timestamp = _root.gameClockMC.gameClock;
response = new LoadVars();
response.onLoad = function(result) {
if (result) {
_root.clearLeftMenu();
_root.gotoAndPlay("portfolio");
}
}
submitData.sendAndLoad("Portals/insertPortal3L2.cfm?r=" add Math.round(Math.random()*99999), response, post);
} else {
error._visible = true;
error.errorText = "You must have at least one Assessed Threat to Submit.";
blocker.gotoAndStop(2);
}
}
Now, the error check (the reason that I added the if statement works, in fact the code in the if statement runs up till the sendAndLoad. Once again, if I remove the if statement this works just fine. Has anyone seen anything like this before
thanks
cognizen
Load XML Doesn't Work On Scene 2
Hi all.
Can anyone explain why loading an XML file doesn't work when it is on scene 2?
If I have the code on scene 1, it works fine but when I switch it to scene 2 the load just fails.
On scene 1, there is a button that the user presses to switch to scene 2. The actionscript on the button is:
on(press){
gotoAndPlay("Scene2");
}
On scene 2, frame 1 I have:
pageLinks = new XML();
pageLinks.load("C:\text.txt");
On scene 2, frame 2 I have:
pageLinks.onData = function(pageLnks) {
trace(pageLnks);
}
On scene 2, frame 3 I have:
gotoAndPlay(2);
The trace never executes on scene 2, but if I change scene 2 to be scene 1, it works fine.
Any ideas?
Thanks in advance,
Damian
Auto Load Next Swf, But Doesn't Work
The menu loads external swf files into a place-holder named 'loader'. However, I'm trying to have it where when the current loaded movieclip inside 'loader' reaches its end (last image), it would automatically load the next swf file. I know this is possible but I can't get it to work.
I'm trying something like this in the main timeline just to test it out:
Code:
if (_root.position._x == -750) {
trace("Okay");
}
What I'm trying to do above is if the x location of 'position' is -750, it would trace "Okay", but that doesn't work, I've also tried using _global.endX and _root.loader but nothing comes up when I scroll through the clips. Any ideas, I know it's not flash. Thanks for any hints or tips you can provide!
Why Does My OnclipEvent Load Pop Up , Not Work On Safari?
I'm using the following code...and it automatically launches a pop up with firefox and IE, but on safari, it don't work. What is going on? Any work around for this?
onClipEvent (load) {getURL ("javascript:NewWindow=window.open('southafrican.h tml','newWin','width='+screen.availWidth+',height= '+screen.availHeight+',left=0,top=0,toolbar=No,loc ation=No,scrollbars=No,status=No,resizable=No,full screen=No'); NewWindow.focus(); void(0);");
}
on (release) {
getURL ("javascript:NewWindow=window.open('southafrican.h tml','newWin','width='+screen.availWidth+',height= '+screen.availHeight+',left=0,top=0,toolbar=No,loc ation=No,scrollbars=No,status=No,resizable=No,full screen=No'); NewWindow.focus(); void(0);");
}
[MX04] Load SWF Files But They Don't Work
Hey guys I'm pretty new to flash.
My problem is this - I have loaded external swf files into my main timeline using the following code -
on (release) { this.box.loadMovie("ElliesMatchingGame.swf", 1);
}
The movie loads (images etc) but the coding doesn't seem to work. The external swf is using simple coding as well, just drag and drop MCs-
on(press) {
mysound = new Sound();
mysound.attachSound("blue");
mysound.start();
startDrag(this);
_root.answer1="";
}
on(release) {
stopDrag();
if (this._droptarget == "/blue") {
_root.answer1="Correct";
_root.answer2 = "";
_root.allCorrect +=1;
gotoAndPlay(2);
}
else{
_root.answer2 = "wrong";
_root.answer1 = "";
gotoAndPlay(3);
}
}
I'm sure i'm doing something really simple wrong! But can anyone help?
Why Does My OnClipEvent Load Pop Up, Not Work On Safari?
I'm using the following code...and it automatically launches a pop up with firefox and IE, but on safari, it don't work. What is going on? Any work around for this?
onClipEvent (load) {getURL ("javascript:NewWindow=window.open('southafrican.h tml','newWin','width='+screen.availWidth+',height= '+screen.availHeight+',left=0,top=0,toolbar=No,loc ation=No,scrollbars=No,status=No,resizable=No,full screen=No'); NewWindow.focus(); void(0);");
}
on (release) {
getURL ("javascript:NewWindow=window.open('southafrican.h tml','newWin','width='+screen.availWidth+',height= '+screen.availHeight+',left=0,top=0,toolbar=No,loc ation=No,scrollbars=No,status=No,resizable=No,full screen=No'); NewWindow.focus(); void(0);");
}
I Can Load External .swf But Buttons Don't Work
I've been banging my head against the wall on this one.
I have my main site (index.swf) that I put a button on one of the sections and the actionscript on the timeline.
Here is the AS on the timeline of my main site (index.swf):
Code:
pgroup1.onPress = function(){
createEmptyMovieClip("picgroup1", 1);
picgroup1.loadMovie("http://rberry883.home.comcast.net/petpics.swf");
picgroup1._x = 0;
picgroup1._y = 160;
picgroup1.border=false;
}
** this will load the external swf (petpics.swf) just fine but the buttons don't work. The button instance name is "pgroup1".
And here is the AS code that is on the movie clip of my external swf (petpics.swf) that is supposed to let the buttons function:
Code:
onClipEvent(load){
this._x = 200;
this._y = 50;
this.div = 5;
}
onClipEvent(enterFrame){
this._x += (endX-_x)/div;
this._y += (endY-_y)/div;
_parent.btnp1.onRelease=function(){
this.endX= 200;
this.endY= 50;
};
_parent.btnp2.onRelease=function(){
this.endX= -50;
this.endY= 50;
};
_parent.btnp3.onRelease=function(){
this.endX= -300;
this.endY= 50;
};
_parent.btnp4.onRelease=function(){
this.endX= 200;
this.endY= -150;
};
_parent.btnp5.onRelease=function(){
this.endX= -50;
this.endY= -150;
};
_parent.btnp6.onRelease=function(){
this.endX= -300;
this.endY= -150;
};
}
Now this swf works on its own if I take the "_parent" tags off ( I also tried with this.) but same results. The buttons have instance names btnp1 - btnp6 and are used to move the movie clip with an instance name of "se" but the buttons don't work when loaded into my main site.
Here is my page I uploaded it to, Once loaded, click on the Photos button and then on the #1 button on the right and you'll see the external swf load but the buttons won't work.
My site: http://rberry883.home.comcast.net
Any help is appreciated.
rberry88
Load Xml On Https Doesn't Work With IE ?
Hi,
I've got a php script on a https url wich extract a database to create an xml file.
With firefox, my swf has no problem to load the xml, but with IE it can't.
Somebody has ever meet this problem ?
I've try to resolved it with "actif content extension" of publish parameters, but it's not the solution.
Thanks for help me.
Realy sorry for my bad english...
Scrollpane - Load Swf - Load Movie Symbol Controled By Buttons And Variables?
Ok i have searched the board, and racked my brain and read hundreads of bit and pieces. So far 'not happy jan'. Anyhow I thought well I shall start a thread where first I ask a question of 'can it be done' then go away try and do it and if fail 'ask how to do it' or if suceed then say 'how i did it'. Of course all questions are going to relate back to this original post so no new threads need to be started. Anyhow onto my question!!
I have a website I want to make. so I started... called it 'site.swf'. now site.swf has a scrollpane in it called 'content'.
Now I have also created 'home.swf' which has 2 movie symbols in it. one called 'homein' the other 'homeout'.
'Homein' is located in frame1 of home.swf and 'homeout' is located in frame2.
When site.swf loads I want to load home.swf into 'content' and home.swf plays 'homein'.
When the user clicks on the first button (in site.swf) 'content' plays 'homeout' before loading 'button1.swf' into 'content' and playing 'button1in'
see the pattern forming. Now I am sure this has been asked thousands of times, but I haven't found it once. At least in a form that is easy to understand.
Now can this method be done, or do i need to go away and rethink it. (my main reason for loading external.swf's is because i wish to preload where needed).
If all this can be done tell me now... I am sure I need to use 2 variables.... 'loadedmovie' and 'tobeloaded' to communiticate with 'content' and to follow the users clicks of buttons.
Thanks for any help.
Trent
Movie Taking Long Time To Load, Needs To Load Faster
I am a loading several movies into level 2 of the main movie. The movie is taking up to 1.35secs to load. The issue is that the images are too big. Can I do something about the movie itself or do I need to compress the images more?
(mx) Transfering Actions Which Load With Movie To Load When Button Is Pressed
hi,
I have some code which draws a line when the mouse is pressed (to when it is released)
This code is within an object, loads when the movie starts and works fine:
Code:
// ***** Set some opening parameters
onClipEvent (load) {
// Make original line invisible
_root.line._visible = 0;
// Initiate some variables
number_lines = 0;
line_active = 0;
}
// ***** Every time the mouse button is released...
onClipEvent (mouseDown) {
// Get the position of the mouse
origin_x = _xmouse;
origin_y = _ymouse;
// Increase the number of lines by one
number_lines++;
// Generate a new line name
name = "line"+number_lines;
// Duplicate a new line
_root.line.duplicateMovieClip(name,number_lines);
// Position the line's end point at mouse position
_root[name]._x = origin_x;
_root[name]._y = origin_y;
// Update line length / orientation
_root[name]._xscale = _root._xmouse - origin_x;
_root[name]._yscale = _root._ymouse - origin_y;
// If this is the start of a new shape
if (!line_active) {
// Set the line tracking variable
line_active = 1;
// Set the start point of the new shape
start_x = origin_x;
start_y = origin_y;
}
}
onClipEvent (mouseUp) {
line_active = 0;
}
// ***** Every time the mouse is moved
onClipEvent (mouseMove) {
// If there's a line currently being drawn...
if (line_active) {
// Update line length / orientation
_root[name]._xscale = _root._xmouse - origin_x;
_root[name]._yscale = _root._ymouse - origin_y;
updateAfterEvent();
}
}
I want the user to press a button before this code is usable - just as with any drawing program.
How do i go about telling the code only to start when the button has been pressed?
thanks,
jeff
Load A Xml File That Contains Urls - Want 2 Load A Movie Instead Of Open URL Links
i'm just wondering how does one go about to load an xml / text file into a text box.. this text file - has url links.. or a href tags.. how do i change it such that the url links can call actionscripts instead of opening the window to a url..
does that make sense?? if it still doens't - go to www.praystation.com
if you click on the "news" section - his urls open/load movie clips how do i make something similar to that
thanks
|