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




How To Call A Mc From A Btn To Insert It Into A Scrollpane



I'd like to know how to call a mc from a btn to insert it into a scrollpane. the mc is not an instance and is not into the scene, it is into the library.

all help is apreciated. Thanks.



FlashKit > Flash Help > Flash Newbies
Posted on: 05-12-2006, 01:12 PM


View Complete Forum Thread with Replies

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

Insert Many CheckBox In Scrollpane
I would like to insert many checkboxes in a scrollpane by rows..
However when i scroll the pane, the checkboxes cannot be seen..
its like it is overlap or something???????

Why????
Can anyone help please...I have already attached the fla. file...

Scrollpane... How To Insert Text?
Hi there. I've just placed a scrollpane into my scene, but I have no idea how to place text into it. Can someone help me? thanks!

Insert Or Call Pdf Document Into Flash Mx
I would like to insert my resume in pdf format into my flash web site for potential employers to view and perhaps print. Is this possible? What would be the best way to accomplish this?

My Symbol Can't Insert Into My Insert Texrt
i have few button to let user click and the symbol will insert into the input text...
i change my input box to 'symbol' but i facing the problem that i can't insert character other than symbol...

pls check it out my fla and try out...

Can't Call Function Created Via Eval Using ExternalInterface.call
I have created a flash movie that acts as an MP3 player. Using ExternalInterface, I pass an array containing cue points in the song to the flash move so that it makes a callback to javascript when it hits certain points in the song. Since I want to deal with these callbacks differently for each song, I have made it so that I can dyanmically change the function that is called from Flash (to Javascript). Here is the code for that piece:

ExternalInterface.addCallback("setCuePointFunction ToCall", this, setCuePointFunctionToCall);

var cuePointFunctionToCall:String='';
var intCurrentCuePoint:Number=0;

function setCuePointFunctionToCall(strFunctionName){
_root.cuePointFunctionToCall=strFunctionName;
}

function reportToJavascript_CuePoint(intCuePointID:Number){
ExternalInterface.call(_root.cuePointFunctionToCal l, intCuePointID);
_root.intCurrentCuePoint++;
}

This works perfectly as long as the function that cuePointFunctionToCall refers to is defined in a script block on the HTML page. However, this project is an AJAX-style thing, and I need to be able to define the function that is triggered on a cue point in code that is dynamically executed at run-time via an "eval' call.

Here's the code that talks to actionscript. This appears in a script block on the main page (not via eval).

function setCuePointFunctionToCall(strFunctionName) {
thisMovie("PushPuppets_Media_Center").setCuePointF unctionToCall(strFunctionName);
//alert(strURL);
}

function thisMovie(movieName) {
var isIE = navigator.appName.indexOf("Microsoft") != -1;
return (isIE) ? window[movieName] : document[movieName];
}

Here's the code that is dyamically being executed via an eval statement in javascript:

setCuePointFunctionToCall("cuePointNew");

function cuePointNew(lngCuePointID) {
alert('New function, cue point: ' + lngCuePointID);
}

This does not work. But if I copy the above function block to the main page (not in the code that is executed via an eval) it does work. I am certain that setCuePointFunctionToCall is being executed properly via the eval - it is definitely changing the function that actionscript will call. This is apparent since it is calling the right function when the function is declared on the HTML page (not in the AJAX-style eval call). So I'm guessing that this has something to do with the scope in which eval operates.

I encountered a very similar problem when I tried redefining a function in the eval call that was already defined on the main page. It just didn't take.

Please let me know if you have any suggestions.

Thanks,

Erich

[F8] Button Inside Scrollpane, Cannot Control MC Outside Of Scrollpane?+emptymc
Hi, first look at the example of how it should work :

http://www.surfacingmedia.com/VIDEOPLAYER2.html
notice the Buttons in the scroller on the right tell the MC on the left to GOTO MC frame i want it too (each frame then holds Player for specific video.)
works great right?

Now when I load this into my main site into an empty movieclip i use for all section content it Does not work at all! sure it loads the first video but the buttons are disabled?
(use link below navigate to photo/video and selet video.)
http://www.surfacingmedia.com/

the code is the same just calls to the videoplayer MC and tells it to goto a certain frame.
it doesnt work when loaded into my empty MC. ?
any suggestions?
If kill the scrollpane altogether, buttons work fine then even loaded into emptyMC. seems once buried in scrollpane its too deep for buttons to work? which for me defeats the purpose kinda.
Note-Flash 8 (i am a code lightweight i used the BEHAVIORS commands gotoand stop on frame select the MC.)

Thanks in advance i will answer some posts while i am here that i can now.

ScrollPane Auto Scroll On Frames Within ScrollPane
Hi Guys,

I am using an instance of the scrollPane component to load in scrollable content, some of the items of content are .swfs that have separate navigation within them. I am wondering how I can get the scrollPane to adjust the amount it can scroll based on the content on each frame of the movie that has been loaded into the scrollPane. Ideally the scrollbar would also turn off when the content is small enough for there to be no need for the scrollbar.

Thanks,

-Jim

Swapping Scrollpane Content With Button Outside Scrollpane
Hi,

I'm terribly new to flash which is probably why I couldn't solve this with any tutorial out there.

I've got a scrollpane, and outside that I have a few buttons working as a nav bar. I want these buttons to load a different movieclip (which isn't in the stage, it's in the library) to the scrollpane.

Using the tutorial on this site (the one where you add or remove a blue movieclip to the scrollpane) I got as far as adding the movieclip to the scrollpane. Problem is, I need the buttons to unload the current movieclip before loading the new one.

(So for example, if the movieclip called "home" is loaded in the scrollpane and I click on the button "Patterns & Textures" I want that button to unload "home" from the scrollpane and load the movieclip "patterns")

My code so far looks like this:



Code:
scrollPane.setStyle("borderStyle", "none");

var i:Number=0;
var mcMain:MovieClip;
function init() {

scrollPane.contentPath = "home";
mcMain = scrollPane.content;
trace(mcMain);

}
init();

brushes_btn.onRelease = function() {

mcMain.attachMovie("brushes", "brushes"+i, mcMain.getNextHighestDepth(), {_y:50*i+5, _x:5});
i++;
scrollPane.invalidate();

};
Taken from the tutorial.

I'm pretty sure I don't need the + i part because I won't have more than one mc in the scrollpane at once, but I don't know how to remove it without screwing it up.

I'd greatly appreciate any help!

How Can I Call I Call An Executable File?
which is the command in flash to execute an .exe file?

Call Javascript With ExternalInterface.call
Hi. I'm trying to call a javascript function from a flash movie.
I'm using IE.

This one works:
AS3: ExternalInterface.call("test();");
javascript:
function test()
{
alert(666);
}

This one doesn't:
AS3: ExternalInterface.call("test(666);");
javascript:
function test(val)
{
alert(val);
}

...it says "undefined" insted of alert(666)...it seems that if i use a field in the function it simply stops working. (I'm accessing the page via: http://localhost/test_embed/myEmbed.html)

Anyone?

Scrollpane Content Not Limited To Scrollpane
I am using the scrollpane component in flash mx. I have content loaded into the scrollpane via actionscript. The content loads up, but the scrollbars scroll it past the edges of the scrollpane. The content then overlaps the rest of my movie(outside the scrollpane. How can I fix this? shouldn't there be a mask there? thanks for your help, garrett

Loading Mc In One Scrollpane From Mc Clip In Another Scrollpane
I'm still stuck.

I have one movie clip with a whole bunch of buttons 'loaded' into scrollpane and I want each button to load a different mc into a different scrollpane when clicked.

I tried using "attachMovie" but I'm still very confused.

Is this what I use?

If so, do I go

on(release){
attachMovie("mc name", "frame label of loaded mc", "level not in use");

}


Any help is greatly appreciated.
Thanks in advance.

Scale Scrollpane Content Not Scrollpane
Friday arvo, fantastic.

Any way I can scale a externally loaded clip sitting in a scrollpane.

I can scale the scrollpane no probs using a slider but I want the scrollpane to be static and the swf inside the scrollpane to scale.

cheers in advance.

H

Postioning Content In Scrollpane Without Using Scrollpane
Hi guys.
Not sure if this is possible. i had a look through the help files but had no luck I have 2 questions so here goes.
i am using V2 components in particular the scrollbar component.
I am attaching an mc to the scrollbar the mc contains several lines of text.
Is it possible to use a button elsewhere in the movie to set the postion of the mc in the scrollpane. Essentially moving the content up or done without using the scroll pane buttons or track bar?
How on earth do i change the colour of the scrollbar track button?

thanks
Paul

Scale Scrollpane Content Not Scrollpane
Friday arvo, fantastic.

Any way I can scale a externally loaded clip sitting in a scrollpane.

I can scale the scrollpane no probs using a slider but I want the scrollpane to be static and the swf inside the scrollpane to scale.

cheers in advance.

H

Insert ?
ok so this is my problem, i have a main movie of flash
called "top" and i need to have it as a header on a html page
so i was wondering if i could have another small flashfile with
only code telling top to call another movie in it like "media"
so that "media" will play inside of "top" is that at all posible??
anyways i hope anyone who read this post is doing good.

How To Insert SWF In Eml
Hi,
Is there any solution to insert SWF in mail, Outlook Express file format (eml)?
If it possible how?
Thanks in advance
georgmorb@ip.osgf.ge
G E O R G E

How To Insert SWF In Eml
Hi,
Is there any solution to insert SWF in mail, Outlook Express file format (eml)?
If it possible how?
Thanks in advance
georgmorb@ip.osgf.ge
G E O R G E

How To Insert
hello
i`m a beginer,pls tell me,after downloading the flash applet,how to place it in my web page?

Insert Mc From One Into Another
Hi kirupians,

can anyone give me a hand with the following?

Say I got an mc..that I attached dynamically to a certain Movie Clip now I need to detach it and insert it into another one that's in a different place (with something like onRelease...) I'm having a hard time cause you can't duplicate movies with dynamically loaded jpgs... it gives me the initial emptyMC with no jpg..

thanks for any help..

URL Insert
I want to create a link to my blog page.

My web address is www.christianseaborn.com
The blog page attached with this is at:
www.christianseaborn.com/blog/

I wanted to attach the URL address for the blog within my Flash document.

I tried both creating a button with the ActionScript
blog_btn.onRelease = function () {
getURL("www.christianseaborn.com/blog/");
}

As well as on a static line of text putting the link in the Property Inspector slot.

Neither works because Flash ignores/eliminates the second "/" (after the word blog) in the address. Thus the browser keeps coming back with an error message saying that the address:
www.christianseaborn.com/blog does not exist...which is true because the address requires the second "/" in order to work.

Any thoughts on how to make this work would be appreciated.

Christian
seaborn.christian@gmail.com

How To Call A Function First And Create A Delay And Call Another Function
Hi, I am new to actionscript. Is it possible for me to call a function first and call the second function after a short delay.

I try to use this codes. But it didnt work

function a(){
trace("A");
setInterval(b(), 1000);

}

function b(){
trace("b");
}

ScrollPane To ScrollPane Communication
I have a scene with two ScrollPanes. One ScrollPane contains a movieclip of thumbnails (used as buttons), the other ScrollPane contains larger pictures. Similar to a photo album. When each thumbnail is clicked, it is supposed to go to a specific frame label of another movie clip within the second ScrollPane.

This is the code I am using for the thumbnail buttons:

on (release) {
_level0.Ads-Scroll-Large.tmp_mc.gotoAndPlay("AD2");
}

I know it has to be something stupid...

Any help would be greatly appreciated!

Many Thanks,
Todd

Loading Mc In One Scrollpane From Mc In Another Scrollpane
I'm still stuck.

I have one movie clip with a whole bunch of pictures as buttons 'loaded' into a scrollpane and I want each button to load a different mc into a different scrollpane when clicked.

I tried using "attachMovie" but I'm still very confused.

Is this what I use?

If so, do I go

on(release){
attachMovie("mc name", "frame label of loaded mc", "level not in use");

}


Any help is greatly appreciated.
Thanks in advance.

One ScrollPane Scrolls Another ScrollPane?
Hi. I have 2 scrollPanes in 1 .swf. The left one loads in an mc with text and links. The right one is the main text content. I want users to be able to click on links in the left pane to vertically scroll the right pane.

Oh. And I need to publish this in Flash 6.

Thanks for any advice.

Calling From ScrollPane To ScrollPane
I am still pretty new to actionscripting...so please bare with me.
Here is what I have...
I have 2 scroll panes
Both of the following scroll panes are on the main stage (frame 1).

One scroll pane has an instance name of "scrollComponent". It is loading the movie "componentList_MC".
In the "componentList_MC" movie is a battery button with an instance name of "batteryBut_btn".

The second scroll pane has an instance name of "viewsScroll". It is loading the movie "viewsPanel_MC".
In the "viewsPanel_MC" I have a frame label of "full" and another label of "230-6368_Battery".
The inital state of the "viewsPanel_MC" is set so that it is on the frame label "full".

I am trying to get it to where when you click on "batteryBut_btn" that it will go to "viewsPanel_MC" and go to the frame label "230-6368_Battery".

Here is the code I have on frame 1 on the actions layer. This is what I have described above and is not working. Any thoughts or suggestions that someone could help me out with?

//12V Battery (230-6368_Battery)
batteryBut_btn.onRelease = function() {
_root.viewsScroll.viewsPanel_MC.gotoAndStop("230-6368_Battery");
};

Insert Jpg Or Gif Into Flash
Hello!

It's possible insert images, jpg or gif, into a Flash Movie with actionscript or other way?

thank's!

How To Insert Video
I have transformed my quicktime video clip to a swf file so that I can insert the video into my flash, but everytime I go to flash and try to import it. It closes flash and opens video..What shoudl i do?

HOW TO INSERT ONE WHOLE MOVIE INTO ANOTHER
HI !! I'M VERYYY NEW AT FLASH ! CAN U PLEASE TELL ME STEP BY
STEP HOW TO PUT DIFFERENTS MOVIES INSITE EACH OTHER SO
THEY CAN PLAY ALL TOGETHER AT ONCE .
THANK U VERY MUCH 4 U TIME AND HELP
TAKE CARE AND PEACE AND GOD BLESS YOU AND
GIVE YOU HEALH, MONEY,LOVE ALL YOU WANT
BYEEEEEEE

Insert Key - Can I Detect If This Is On Or Off?
Can I detect to see if the Insert Key is on or off when I load an swf? I know I can check to see if it is pressed while the swf is playing, but I need to know if it's on or off to start with.
Cheers for any response or help

charlie

How To Insert A Button
i created an enter button.. now how do i insert it into the stage ?????? help ..

Insert Sound
What sound file types can I put to flash and what need I to write in the Sound Symbol box to play a sound that is in my hard disk?

Help Me Please-i Can Not Insert Sound
I am very new to flash mx
I want to know how to insert music into my flash movie but the problem is that,whenever I select file>import to library then select the music I want in my movie a small browser comes up saying that it can not read the files-but the thing is I know that the file types are mp3. and waves which flash mx should be able to read!!
please help!!

How Do I Insert A Preloader..?
can anyone gimmie a quick bit of help, about how to insert a preloader.
i have a small movie with sound made up, 1.3 megs and i downloaded a nice preloader, but i have no idea on how to make it work :/

thank you

Insert Mouse
I have download some mouse cursor movies.
How do I insert them into my webpage?

Insert A HTML Into A .swf?
Hi ,i have a site made in flash , and i like to generate dinamicly an html with php, and that html inserts on my .swf (inside), how can i do that?
thanks!

pd: i don want to do a hybrid site , i want to put the html into the swf.

Insert Formula
How to insert this formula in actionscript, i cant find the commands:
m=d*((1-k)/(1-k^n))

I cant find the last part k^n. It's k exponented to n.

sorry for my english.

Insert File To ...
how can i make to attach a file (jpeg - tiff - zip - png - bmp - etc)to a mailform to send to a friend?

Insert Preloader
Hi!

Thank you for reading this.
It must be possible to add or insert a preloader after I have made the main Flashanimation. I just do not know how.

Maybe it is possible to change the order of sceans so that if you have four scenes, the 4th start first??

Hope somone can help me with this problem, Well, problem for me,but not for others, I hope.

Thank you for any answers!

//ikaros

___________________________
peace, not war!

How Can I Insert A VBScript?
Pues eso

The problem is that I need to insert a VBScript, I think, it calls a window out of the proyector, but I don't know how to put it in the Script, can you help me???

Thanks

Insert Keyframe
what key do you hit to insert key frame in Mx?

I hate doing the drop down insert option over and over...


Thanks

How To Insert Pong .fla
HI i was wondering how to insert a pong fla into my original movie as its preloader. also how to i make it start the movie once the game ends? thanks

Insert Mc Inside Another Mc
What's the best way to insert two movie clips inside another mc? I tried copy frames and paste frames. When I work with the final instance, it revert back to a graphic.

How To Insert *.asf To Flash
I use the MediaController insert a mp3 type file to the swf
but I don't know how o insert *.asf *.ram.......................

ChildNodes[insert Value Here?]
trace(obj_xml.childNodes[1].childNodes); works. subbing in param_txt doesn't. I need a way to change that value depending on the value of i. any suggestions?


Code:
function clientGen() {
for (var i = 0; i<client_xml.length; i++) {
_root.blankMC.attachMovie("client", "client"+i, i);
client = _root.blankMC["client"+i]
client._x = 272 + client._width*i;
client._y = 256;
client.param_txt = i;
client.name_txt = client_xml[i].attributes.name;
client._alpha = 0;
j = 0;
client.onEnterFrame = fadeIn;
client.onRelease = function() {

trace(obj_xml.childNodes[param_txt].childNodes);

Insert Symbol
i was supposed to put this drawing where i erase a tiny bit of the letter each frame and by the end of the movie i had 136 frams where the wrd REDBOX draws itself. u know?

well

i was supposed to put all 136 frams under "Insert Symbol" under a symbol named Laser on clip

is there anyway to move all 136 frames to the symbol or do i have to restart it over?

Insert Book
hi all , i wanna to ask about the books, and how i can insert all pages of the book inside flash, or how can i deal with book in flash
wa can talk about 1000 pages will be puted in the flash.

what is the best way to do that in flash

thank u alot

Insert Flash Into PP
Are you able to insert Flash into Power Point... If so Does anyone know of a tutorial how to do it or can tell me how... I tried sever ways but been unsuccessful...

Insert A MC Into A Clipholder
Hi Guys,

need to insert a MC into graphic labeled "holder" on my page.

I did this before and I'm missing something simple.

action: on press
load movie

url: "newsom.swf"
target: "holder"
(don't send)

instance is labeled holder, can't think of what else. any help?

and thanks in advance.

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