Solved

Problem with rollover in movieclip in scrollpane

Posted on 2006-11-01
2
326 Views
Last Modified: 2008-02-01
This is a followup question from this thread:
http://www.experts-exchange.com/Web/WebDevSoftware/Flash/Q_22044839.html

Now I have this script that works excellent with the help from the great Aneeshchopra.

my_mc is a empty movieclip in my library
and clip1 and clip2 are the clips i need to display in my scrollpane.

mypane.contentPath = "my_mc";
mycontainer = mypane.content;
temp = mycontainer.attachMovie("clip1", "clip1", 1, {_y:0});
temp2 = mycontainer.attachMovie("clip2", "clip2", 2, {_y:18});

after this script here above which works excellent like i mentioned I have this script because I want to interact with clip1 and clip2:

clip1Class.prototype = new MovieClip();
Object.registerClass("clip1", clip1Class);
clip1Class.prototype.onRollOver = function() {
      trace("rollover");
};

But I cant get it to do the trace?

Does anybody know whats the problem here?



0
Comment
Question by:Fern2
2 Comments
 
LVL 23

Accepted Solution

by:
Zeffer earned 500 total points
ID: 17852604
you need a constructor for the class.. try this..

function clip1Class() {}
clip1Class.prototype = new MovieClip();
clip1Class.prototype.onRollOver = function() {
     trace("rollover");
}
Object.registerClass("clip1", clip1Class);


Z



0
 
LVL 1

Author Comment

by:Fern2
ID: 17855866
thx Zeffer. Brilliant
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

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. …
Here are some practices and techniques that can be adopted into your Flash/Flex application development process. Note: Not all "performance tips" provide an immediately-recognizable benefit.   This article does not include timing validation data,…
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…
The goal of the tutorial is to teach the user how to set there setting in Adobe Flash Media Live Encoder and YouTube for optimal video and audio quality.

867 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now