Solved

movie is not loading while button click

Posted on 2004-09-24
8
227 Views
Last Modified: 2010-04-03
movie is not loading while button click. i called action like loadMovie("C:\folder1\folder2\folder3\movie.swf","1"); but movie did not open. i want button will be replced by a static image as soon as i click button. whats wrong ?in fact my movie is just a simple image.
0
Comment
Question by:cofactor
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
  • 2
8 Comments
 

Author Comment

by:cofactor
ID: 12141691
i am using flash MX
0
 
LVL 6

Expert Comment

by:nishasrilankan
ID: 12141936
loadMovie("C:\folder1\folder2\folder3\movie.swf","1");

uncomment "1"
0
 
LVL 6

Expert Comment

by:nishasrilankan
ID: 12141944
I meant removoe quotaions of 1
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 4

Expert Comment

by:mrdilliard
ID: 12147908
btnClicked.loadMovie("C:\folder1\folder2\folder3\movie.swf");

You need to take out the "1" altogether...it's supposed to be either "GET" or "POST" if you do use it, but you don't need it in this case.

btnClicked is the name of your button, or where you want the movie to be loaded.
0
 
LVL 4

Expert Comment

by:mrdilliard
ID: 12147920
Excuse me...I made a slight mistake: the third parameter is the method, where it would be "GET" or "POST"

The second parameter, where you have "1" should be the name of the movie clip you want to load into. You do leave the quotations on, although I'm not sure they're required.

loadMovie("C:\folder1\folder2\folder3\movie.swf","btnClicked");
0
 

Author Comment

by:cofactor
ID: 12159419
hi...... none of the suggestions  worked.

what i want >>

 i want  a small button . As soon as the user click on the  button it will be replaced by a JPG image.

what i did >> 

i first made my JPG image a movie (static movie ) having .swf extension. then i tried to load this .swf movie as the button click action.

can you tell why it is not working ?



The sucess i have got till now >>

 i have been able to get the button correctly bcoz as i am rolling mouse its color changing  for 'over' ,'on' and  'down' conditions but as soon as i click on the button nothing is happening .....why ? whats wrong ?

N.B > actually , this button will be highlighted on a map...as soon as you click on the button it would be replaced by a separate JPG image ...thats what i am trying to do.

in fact its just map zooming by selecting individual city(buttons) using individual maps ( JPG images ).

plz help
thanks
0
 

Author Comment

by:cofactor
ID: 12159479
here are the error reports. i tried different way but no sucesses ....here 4 trials that i tried.
.......

trial 1
---------

Scene=Scene 1, Layer=Layer 1, Frame=1: Line 1: Statement must appear within on handler
     B.loadMovie("C:\folder1\folder2\folder3\movie.swf",1);

trial 2
--------
Scene=Scene 1, Layer=Layer 1, Frame=1: Line 1: Statement must appear within on handler
     loadMovie("C:\folder1\folder2\folder3\movie.swf",1);

trial 3
-------

Scene=Scene 1, Layer=Layer 1, Frame=1: Line 1: Statement must appear within on handler
     loadMovie("C:\folder1\folder2\folder3\movie.swf","B");

trial 4
-------
Scene=Scene 1, Layer=Layer 1, Frame=1: Line 1: Statement must appear within on handler
     B.loadMovie("C:\folder1\folder2\folder3\movie.swf");
0
 
LVL 4

Accepted Solution

by:
mrdilliard earned 30 total points
ID: 12160049
Looks like you're trying to add the actions onto a movie clip. You need to put an on handler around your code, such as:
on(release){
     //code goes here
}

or you can just put it on a frame and it'll run when it reaches the frame.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
SWF won't scale? 4 530
Missing Plugin for Firefox - Can't View Content 7 180
Animating text  - electrons orbit around letter M 12 92
Web browser crash when play videos 24 398
I come across a lot of question about how to access things in the document class from a movieclip, or accessing something from a movieclip in the document class. It took me a while to figure this out but once I did it makes life so much easier. …
The last time I worked with Flash and Socket connections was in AS1. A recent project required flash connecting to a Socket, and sending receiving information - we figured it would be easy enough - we all know about the socket policy documents and c…
In this tutorial viewers will learn how to create a basic motion tween animation in Flash Open a new document in Flash: Draw/import an image: Press CTRL + F8 to convert it into a graphic symbol: Select a frame (how long you want the tween to last): …
The goal of the tutorial is to teach the user how to live broadcast using Flash Media Live Encoder and connecting it to YouTube to broadcast. Log into your Youtube account, choose live stream settings, start live stream from Flash Media Live Enc…

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question