ActionScript 3.0 :: Navigatetourl With Addchild To Control Depth?

May 7, 2010

does that make sense at all? here's what i'm trying to do, the code is below. i'm building a touchscreen interface for a tradeshow, which mainly is a slideshow, with three buttons, one of which, when clicked, needs to load the company's webpage. i need to keep the webpage "inside" my environment and keep the navigation buttons on screen, so the user can touch the other two buttons for the rest of the content. so far, i've got an image on the stage, then call a button with addchild. i've got that loading a movieclip via addchild, also, which then calls the url, then i lose my nav button. is it possible to somehow load a url, and control it's depth index? or, accomplish the desired result in a different way?

var button_1:btn1 = new btn1();
button_1.x = 196;
button_1.y = 860;

[code].....

View 2 Replies


Similar Posts:


Flex :: Change Depth When Using AddChild?

Jun 9, 2010

I'm adding a bg to the same canvas, but it's overlapping everything added before it.

View 2 Replies

ActionScript 2.0 :: Control The Depth Of Buttons?

Nov 1, 2005

i'm trying to control the depth of some buttons which are all pretty close, and on mouse over, each buttons gets bigger (150% more or less), the problem comes when i want to control the depth in order to place the rollovered button above it's neighbours.... guess it could be done by actionscript...here is a link i found that explains how to do that, i'm quite beginner in flash and it is too much level for me, eventhought i've reatten it carefully.

View 1 Replies

ActionScript 3.0 :: Movie Clip Depth Control?

Jan 31, 2011

I'm having a huge problem trying to place movie clip under other stuff. Here is the thing I have three layers and I need to place vid_mc on the midle one i've tried creating a movie clip and intancing it as vid_mc and removing de addChild (vid_mc) from the code but ir didn't work.

[Code]...

View 4 Replies

ActionScript 2.0 :: Depth Based Timeline Control

Dec 30, 2007

I need to know how to control a MovieClip based on it's depth.MovieClip at n depth .gotoAndStop(2);

View 1 Replies

Actionscript 3 :: Control The Depth (z Index) Of Bordercontainer In Flex?

Mar 3, 2012

i'm desperately trying to set my border container the highest z-index so it will always appear on top.

how can I know how many objects are in my flex stage, so i'll be able to set the bordercontainer the highest depth? what shell i write in the depth property in order the border container would always be on top? (it's important to mention that i created dynamic objects)

<s:BorderContainer includeIn="state2" width="200" height="200" backgroundColor="#992F2F"
horizontalCenter="-61" verticalCenter="23" depth.state2=currentState.num>
</s:BorderContainer>

View 1 Replies

ActionScript 3.0 :: Flash Movieclip On Stage Depth Control?

Feb 23, 2011

I have about 85 movie clips on stage and they all have startDrag with MOUSE_DOWN.here is the thing I need the active one to come forward to the top of all others.I tried using:

setChildIndex(e.currentTarget, 85)

on the mouse over function but its not working its giving me an error 1118: Implicit coercion of a value with static type Object to a possibly unrelated type flash.displayisplayObject.

View 2 Replies

Actionscript :: Control The Depth (layer Position) Of A Flash Video?

Jun 4, 2009

I would like to place a video object above one movieClip instance ("mc"), but below another movieClip instance ("mc_top").

I instantiated the _root.flashVid object by dragging a "New Video..." from the Library to the stage, and giving it the instance name "flashVid".

I create mc, then paint a blue box, then I create mc_top, and paint a yellow box. The flashVid instance is on the Stage (_root) from the beginning. Now how do I get the flashVid above "mc" but below "mc_top"?

// Create movieclips and paint boxes.
var mc:MovieClip = _root.createEmptyMovieClip("test",
_root.getNextHighestDepth());
mc.beginFill(0x0000ff, 50);

[Code].....

View 3 Replies

ActionScript 3.0 :: Depth Control On Isometric Grid With Multi Tiled Objects

Mar 29, 2011

i am creating a isometric game looks something like farm ville and city ville..i almost done everything. but but problem is only with sorting depth. find the attached .fla. this code is working in certain situations but not every time.

View 1 Replies

ActionScript 3.0 :: Movie Clip Depth Control ... 1118: Implicit Coercion Of A Value With Static Type Object

Feb 23, 2011

I have about 85 movie clips on stage and they all have startDrag with MOUSE_DOWN.
 
here is the thing I need the active one to come forward to the top of all others.
 
I tried using:
 
setChildIndex(e.currentTarget, 85)
 
on the mouse over function but its not working its giving me an error
 
1118: Implicit coercion of a value with static type Object to a possibly unrelated type flash.display:DisplayObject.

View 2 Replies

ActionScript 3.0 :: Control Nested MC Created With AddChild?

Jan 20, 2011

i tried a lot but couldn't fix the problem..

why is the following code is not working?

[Code]...

View 4 Replies

ActionScript 3.0 :: Control A Movieclip Which Is 'introduced' By The AddChild Property?

May 7, 2010

"How to control a movieclip which is 'introduced' by the AddChild property in a other movieclip (for example PageContainer).

For my website, I use the this code:

Actionscript Code:
var p1:page1 = new page1;var currentpage:String;pageContainer.addChild(p1); currentpage="home";stop();function button1Over(event:MouseEvent):void {button1.gotoAndPlay(2); // Mouse-over animation begin}function

[code]...

Quote:

TypeError: Error #1010: A term is undefined and has no properties.

"How to set the statement to a good one, so I can start the closing animation in the Page1-MC which is in PageContainer by the AddChild-property?

View 4 Replies

ActionScript 2.0 :: Putting A Movieclip Into Highest Depth Without Knowing Which Clip Is In The Highest Depth

May 11, 2004

putting a movieclip into highest depth without knowing which clip is in the highest depth

View 2 Replies

ActionScript 3.0 :: AddChild From A Class - Get The Error "1180 : Call To A Possibly Undefined Method AddChild?

Jun 15, 2011

I'm trying to have a class file which can add objects to the stage via addChild; however, when I call addChild from within the class file, I get the error "1180: Call to a possibly undefined method addChild." I've tried importing flash.display.* and that doesn't fix the problem. Does the class file have to extend Sprite or MovieClip to be able to add objects to the stage?

View 8 Replies

ActionScript 3.0 :: Box2d Addchild - 41061: Call To A Possibly Undefined Method AddChild Through A Reference With Static Type Class

Jan 16, 2012

I have downloaded Box2d ([URL]) and created a project that looks like this: [URL]. catalyst is the green cube and it has the base class "shapes.box", it is inside "world" which has the base class "wck.World". What i want to do is to add another "catalyst" from the library inside "world" when i click on add_btn. I tried to accomplish this by this code:

[Code]...

Symbol 'buttons', Layer 'Actions', Frame 1, Line 41061: Call to a possibly undefined method addChild through a reference with static type Class.

View 9 Replies

ActionScript 3.0 :: Difference Between Mc.stage.addChild And Mc.addChild?

Jan 20, 2011

I have the followings:

_p:Player (which is a MC)
a1:Animation1 (which is a MC)
_p.addChild(a1); //doesn't display anything
_p.stage.addChild(a1); //displays a1

Why won't the MC display a child without using his stage?

View 1 Replies

ActionScript 3.0 :: Difference Between AddChild And Parent.addChild?

Aug 11, 2009

I'm trying to resolve an issue that reared it's ugly head yesterday.Frame one of main timeline I have the following code:

Code:
import flash.display.MovieClip;
import flash.events.MouseEvent;

[code]....

The newMC doesn't show up.If I add 'parent.' in front of the addChild then it appears.mc_LibItem has a base class of "flash.display.MovieClip" and is exporting for ActionScript and on frame one.For grins I created a new .fla and began messing around with the same addChild idea and it worked.

View 14 Replies

ActionScript 3.0 :: AddChild, RemoveChild And AddChild?

Oct 30, 2005

somewhat understood the basics of adding and removing children, however, I am facing another problem. After using the removeChild Function, I can't seem to add another child.For example:

ActionScript Code:
var attachedMC = new (getDefinitionByName("Content1") as Class)()
Page.addChild(attachedMC);

[code].....

View 3 Replies

ActionScript 3.0 :: Load External SWFs, AddChild(Loader) Versus AddChild(Loader.content), Etc?

Jul 29, 2009

I have a main "shell" swf which, by clicking several buttons, will load/unload various external swfs into a Placeholder_mc which resides on the main timeline in Shell.swf In the documentation and tutorials I've seen a couple different methods, and I'm not sure I quite understand the difference, or at least the reason you would use one over the other...In the 1st method, you can just add the Loader object using the addChild() method:

Code:

var myLoader:Loader = new Loader();
var myURLRequest:URLRequest = new URLRequest("ExternalFileA.swf");
myLoader.load(myURLRequest);
Placeholder_mc.addChild(myLoader);

This will apparently add myLoader to the display list once it has completely loaded.The 2nd method, you supposedly can add the Loader.content; however, it appears you can only do this once the content has completed loading, so you need to incorporate an event handler with the contentLoaderInfo object:

Code:

var myLoader:Loader = new Loader();
var myURLRequest:URLRequest = new URLRequest("ExternalFileA.swf");
myLoader.load(myURLRequest);

[code]....

What are the pros/cons of adding the entire Loader object, as opposed to the Loader.content and vice versa?

View 7 Replies

ActionScript 3.0 :: How To Use NavigateToURL

Jul 31, 2009

i have an xml file and i have created a gallery that loads thumbs at the start.what i want is that when user click on one of the thumb then it should open the big picture in another browser. i actually use it for swf files. swf files will be loaded in other window. my code is here

Code:
var xmlLoader:URLLoader = new URLLoader();
var imageLoader:Loader;
var xmlList:XMLList;

[code]....

View 0 Replies

ActionScript 3.0 :: NavigateToURL With PHP POST?

May 1, 2009

PHP Code:

var req:URLRequest = new URLRequest ("http://localhost/SE/processimage.php");
var vars:URLVariables = new URLVariables ();
vars.awd = "awd";

[code]...

When I load that url the variable is sent using the GET method instead. It appears in the url in the browser and the browser shows an error first then "awd", meaning it worked for $_GET. I tried both req.methods and tried adding "_self" and "_blank" and also on different browsers. It still uses GET.

View 2 Replies

ActionScript 3.0 :: For Loop And NavigateToURL

Feb 4, 2010

I'm having problems with creating a for loop to work with my CLICK state with navigateToURL.Can someone please show me the ways of my errors. I'm sure it is simple. Been out of the game for a while and coming in new to AS3. The roll states work fine.[code]

View 8 Replies

ActionScript 3.0 :: Dynamic Url Within NavigateToURL?

Jan 2, 2011

currently i have the main scene and within this scene i have a button with the value bg_src Also in the scene is a movieclip containing several frames, each frame with a different image and stop();, a different button simply tells this movieclip to go to the next frame, the last frame in that movieclip returns it to the first frame, so it will continuously loop through the images when the button is clicked, one image at a time.

Problem i am having is that i want the button with the value bg_src to link to the original source of the background images when it is clicked, whilst remaining part of the main scene and not within the movieclip.

lets assume image1 was [URL] and image2 was [URL] clicking the background change button would switch the background image to the second image, and the background source button would then, instead of opening a new page to[URL] when clicked, would then open a page to [URL]instead.

The code i have thus far is as follows :

Code:

bg_src.addEventListener(MouseEvent.CLICK, onBgsrc, false, 0, true);
var buttontext:TextFormat = new TextFormat();
buttontext.font = "Verdana";
buttontext.color = 0x424647;

[code]....

View 2 Replies

ActionScript 3.0 :: NavigateToURL With PHP POST

Feb 23, 2011

So I googled this problem and found like 3 threads with the exact same problem and what fixed their problem didn't fix mine, plus those threads are pretty dated. So I thought I'd get a more up to date answer.

[Code]...

When I load that url the variable is sent using the GET method instead. It appears in the url in the browser and the browser shows an error first then "awd", meaning it worked for $_GET. I tried both req.methods and tried adding "_self" and "_blank" and also on different browsers. It still uses GET.

View 4 Replies

ActionScript 3.0 :: Using GotoAndPlay Then NavigateToURL?

Feb 14, 2009

I'm having problems with my animation getting cut of by my navigateToURL code. What is supposed to happen is,If you click on "buttonBtn" it triggers a animation. At the end of the animation it is supposed to stop and bring up a url. I've used gotoAndPlay ("frm") and navigateToUrl. Each time I test it in the browser the animation will begin, but the url comes up before the animation is finished. How do I allow the animation to play all the way through and then retrieve the url?

stop();
//SimpleButton ButtonBtn;
function handleClick( pEvent:MouseEvent):void
{

[code]....

View 9 Replies

ActionScript 3.0 :: Can't Get Navigatetourl To Work

Mar 8, 2009

i've created a flash animation with as3. at the end of the timeline i've got a stop(); action on the last frame which is working just fine. on the following frame i have the navigatetourl action navigateToURL(new URLRequest [URL]} for some reason which i've been incapable of figuring out it will not automatically flip to the page i have written in my action when the animation has finished playing.

View 8 Replies

ActionScript 3.0 :: NavigateToURL Outside Of Domain

Nov 2, 2008

This is the code I want to use to direct a user to a different web page-

function linkToBiblioteca(event:MouseEvent) {
var request = new URLRequest('www.biblioteca.buap.mx');
navigateToURL(request,"_blank");
}

- but it trys to open inside of my directory. How can I avoid this?

View 3 Replies

ActionScript 3.0 :: NavigateToURL To Certain Frame

Nov 23, 2008

I'm kinda new with Flash but I've managed to create a menu for a homepage. Now when I click on one of the menu links - the page opens up in a new window. But I don't want that at all. I want the page to open up in another frame called mainframe. I've tried a number of things already; changing from "mainframe" to "_mainframe" and back, trippelchecking that the frames name really is mainframe so there's no typo. I've also changed the name of the mainframe both in the htmlfile and the code but that didn't work either.

Here's my code:
var linkabout:URLRequest = new URLRequest("about.html");
//...// function aboutClick(event: MouseEvent):void {
if(subDown[1] == true) {
//true = submenyn Īr nere o ska upp
subAbout_mc.gotoAndPlay(15);
[Code] .....

View 8 Replies

ActionScript 3.0 :: IE Blocks NavigateToURL As Pop-up?

Apr 2, 2010

On a game we just completed in Flash Builder 4, there are a couple of links like this:
 
var sponsorLink:String = http://www.plantersplace.com/;
navigateToURL(new URLRequest(sponsorLink), _blank);     
 
IE 7 in some installations is treating this as a popup. Firefox 3.6, Chrome 5, Safari 4 all fine.
 
The game in question is at [URL]
 
Click "continue without logging in, then click "show hint".  Click the hint.  This should fire the above code and open a new window.
 
Several users in IE report this gives them a pop up alert.  I am trying to find out why and what can be done about it.  I have tried the solution I found at Zorked but people STILL say they are getting popup alerts.

View 1 Replies

ActionScript 3.0 :: NavigateToUrl - IE8 Pop Up Block

Jun 30, 2010

I have a question: The following code, which works OK in Firefox and Safari, gets IE8 to throw a pop up block The simple code:

[Code]...

View 3 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved